billbarker 01/12/13 19:47:26 Modified: src/share/org/apache/tomcat/util JavaGeneratorTool.java Log: Fix indexing problem on Mangler. Just a classic 0/1 based indexing problem. Fix for bug #5365 Reported by: Cory [EMAIL PROTECTED] Revision Changes Path 1.3 +2 -2 jakarta-tomcat/src/share/org/apache/tomcat/util/JavaGeneratorTool.java Index: JavaGeneratorTool.java =================================================================== RCS file: /home/cvs/jakarta-tomcat/src/share/org/apache/tomcat/util/JavaGeneratorTool.java,v retrieving revision 1.2 retrieving revision 1.3 diff -u -r1.2 -r1.3 --- JavaGeneratorTool.java 2001/08/03 02:51:44 1.2 +++ JavaGeneratorTool.java 2001/12/14 03:47:26 1.3 @@ -71,14 +71,14 @@ if(index == -1 ) continue; while (index != -1) { int endIdx=index+keywords[i].length(); - // System.out.println("XXX " + s + " " + index + " " + endIdx ); + System.out.println("XXX " + s + " " + index + " " + endIdx ); // Is it a full word ? if( index>0 && s.charAt( index-1 ) != '/' ) { index = s.indexOf(keywords[i],index+3); continue; } - if( (s.length()>endIdx+1) && s.charAt( endIdx+1 ) != '/' ) { + if( (s.length()>=endIdx) && s.charAt( endIdx ) != '/' ) { index = s.indexOf(keywords[i],index+3); continue; }
-- To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]> For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>