@@ -135,13 +135,13 @@ protected String parseStringValue(
135
135
int endIndex = findPlaceholderEndIndex (buf , startIndex );
136
136
if (endIndex != -1 ) {
137
137
String placeholder = buf .substring (startIndex + this .placeholderPrefix .length (), endIndex );
138
- if (!visitedPlaceholders .add (placeholder )) {
138
+ String originalPlaceholder = placeholder ;
139
+ if (!visitedPlaceholders .add (originalPlaceholder )) {
139
140
throw new IllegalArgumentException (
140
- "Circular placeholder reference '" + placeholder + "' in property definitions" );
141
+ "Circular placeholder reference '" + originalPlaceholder + "' in property definitions" );
141
142
}
142
143
// Recursive invocation, parsing placeholders contained in the placeholder key.
143
144
placeholder = parseStringValue (placeholder , placeholderResolver , visitedPlaceholders );
144
-
145
145
// Now obtain the value for the fully resolved key...
146
146
String propVal = placeholderResolver .resolvePlaceholder (placeholder );
147
147
if (propVal == null && this .valueSeparator != null ) {
@@ -171,10 +171,9 @@ else if (this.ignoreUnresolvablePlaceholders) {
171
171
}
172
172
else {
173
173
throw new IllegalArgumentException ("Could not resolve placeholder '" +
174
- placeholder + "'" + " in string value [" + strVal + "] " );
174
+ placeholder + "'" + " in string value \" " + strVal + "\" " );
175
175
}
176
-
177
- visitedPlaceholders .remove (placeholder );
176
+ visitedPlaceholders .remove (originalPlaceholder );
178
177
}
179
178
else {
180
179
startIndex = -1 ;
0 commit comments