kinman      2002/09/06 14:40:53

  Modified:    jasper2/src/share/org/apache/jasper
                        JspCompilationContext.java
  Log:
  - Fixed 12381: _ as the first char of the JSP file needs to be escaped.
  
  Revision  Changes    Path
  1.20      +6 -5      
jakarta-tomcat-jasper/jasper2/src/share/org/apache/jasper/JspCompilationContext.java
  
  Index: JspCompilationContext.java
  ===================================================================
  RCS file: 
/home/cvs/jakarta-tomcat-jasper/jasper2/src/share/org/apache/jasper/JspCompilationContext.java,v
  retrieving revision 1.19
  retrieving revision 1.20
  diff -u -r1.19 -r1.20
  --- JspCompilationContext.java        21 Aug 2002 17:56:03 -0000      1.19
  +++ JspCompilationContext.java        6 Sep 2002 21:40:53 -0000       1.20
  @@ -311,8 +311,9 @@
           int iEnd = jspUri.length();
           StringBuffer modifiedClassName = 
               new StringBuffer(jspUri.length() - iSep);
  -     if (!Character.isJavaIdentifierStart(jspUri.charAt(iSep))) {
  -         // If the first char is not a legal Java letter or digit,
  +     if (!Character.isJavaIdentifierStart(jspUri.charAt(iSep)) ||
  +         jspUri.charAt(iSep) == '_' ) {
  +         // If the first char is not a start of Java identifier or is _
            // prepend a '_'.
            modifiedClassName.append('_');
        }
  
  
  

--
To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>

Reply via email to