You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tomcat.apache.org by cr...@locus.apache.org on 2000/04/08 00:27:53 UTC
cvs commit: jakarta-tomcat/src/share/org/apache/jasper/compiler Parser.java
craigmcc 00/04/07 15:27:52
Modified: src/share/org/apache/jasper/compiler Parser.java
Log:
Handle single-character custom tag names correctly. Also avoided an NPE
if the prefix and colon were there, but the tag name was not. Thanks to
jcollins@point2.com for the fix!
PR:197
Submitted by: jcollins@point2.com
Revision Changes Path
1.19 +2 -3 jakarta-tomcat/src/share/org/apache/jasper/compiler/Parser.java
Index: Parser.java
===================================================================
RCS file: /home/cvs/jakarta-tomcat/src/share/org/apache/jasper/compiler/Parser.java,v
retrieving revision 1.18
retrieving revision 1.19
diff -u -r1.18 -r1.19
--- Parser.java 2000/03/15 19:27:39 1.18
+++ Parser.java 2000/04/07 22:27:52 1.19
@@ -765,10 +765,9 @@
return false;
}
String prefix = tag.substring(0, i);
- String shortTagName = null;
- if (++i < tag.length()-1)
+ String shortTagName = "";
+ if (++i < tag.length())
shortTagName = tag.substring(i);
-
/*
* Check if this is a user-defined tag; otherwise we won't touch this...