Skip to content

PropertyPlaceholderHelper#findPlaceholderEndIndex does not work for custom placeholderPrefix [SPR-7574] #12231

@spring-projects-issues

Description

@spring-projects-issues

Matt Kusnierz opened SPR-7574 and commented

The logic is incorrect within the findPlaceholderEndIndex method:

version 3.0.1 line 173
version 3.0.4 line 193

index = index + this.placeholderPrefix.length() - 1;

I think this line should read:

index = index + this.placeholderSuffix.length();

The code as it stands only works at the moment because the default prefix "${" is 2 characters and the default suffix "}" is 1 character.


Affects: 3.0.4

Reference URL: http://forum.springsource.org/showthread.php?t=95476

Attachments:

Referenced from: commits eda6268

Metadata

Metadata

Assignees

Labels

in: coreIssues in core modules (aop, beans, core, context, expression)type: bugA general bug

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions