XmlValidationModeDetector: length of a string is always greater than index of any of its characters [SPR-11477] #16102
Labels
in: core
Issues in core modules (aop, beans, core, context, expression)
status: backported
An issue that has been backported to maintenance branches
type: bug
A general bug
Milestone
Rajeev Bahuguna opened SPR-11477 and commented
The method org.springframework.util.xml.XmlValidationModeDetector::hasOpeningTag should have this:
return (openTagIndex > -1 && content.length() > (openTagIndex+1) && Character.isLetter(content.charAt(openTagIndex + 1)));
in place of the current:
return (openTagIndex > -1 && content.length() > openTagIndex && Character.isLetter(content.charAt(openTagIndex + 1)));
Affects: 3.2.8, 4.0.2
Referenced from: commits 1763bfb, 69c54a0
Backported to: 3.2.9
The text was updated successfully, but these errors were encountered: