tomcat-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From lu...@apache.org
Subject cvs commit: jakarta-tomcat-jasper/jasper2/src/share/org/apache/jasper/compiler Generator.java
Date Thu, 25 Mar 2004 21:53:13 GMT
luehe       2004/03/25 13:53:13

  Modified:    jasper2/src/share/org/apache/jasper/compiler Generator.java
  Log:
  Fixed Bugzilla 27948 ("NPE with null fragment")
  
  Revision  Changes    Path
  1.229     +8 -8      jakarta-tomcat-jasper/jasper2/src/share/org/apache/jasper/compiler/Generator.java
  
  Index: Generator.java
  ===================================================================
  RCS file: /home/cvs/jakarta-tomcat-jasper/jasper2/src/share/org/apache/jasper/compiler/Generator.java,v
  retrieving revision 1.228
  retrieving revision 1.229
  diff -u -r1.228 -r1.229
  --- Generator.java	25 Mar 2004 21:44:35 -0000	1.228
  +++ Generator.java	25 Mar 2004 21:53:12 -0000	1.229
  @@ -1986,11 +1986,6 @@
   
               n.setBeginJavaLine(out.getJavaLine());
   
  -            // Invoke fragment, unless fragment is null
  -            out.printin("if (");
  -            out.print(toGetterMethod(n.getTextAttribute("fragment")));
  -            out.println(" != null) {");
  -            out.pushIndent();
               // Copy virtual page scope of tag file to page scope of invoking
               // page
               out.printil(
  @@ -2002,8 +1997,16 @@
               } else {
                   out.printil("_jspx_sout = null;");
               }
  +
  +            // Invoke fragment, unless fragment is null
  +            out.printin("if (");
  +            out.print(toGetterMethod(n.getTextAttribute("fragment")));
  +            out.println(" != null) {");
  +            out.pushIndent();
               out.printin(toGetterMethod(n.getTextAttribute("fragment")));
               out.println(".invoke(_jspx_sout);");
  +            out.popIndent();
  +            out.printil("}");
   
               // Store varReader in appropriate scope
               if (varReaderAttr != null || varAttr != null) {
  @@ -2023,9 +2026,6 @@
                   }
                   out.println(");");
               }
  -
  -            out.popIndent();
  -            out.printil("}");
   
               n.setEndJavaLine(out.getJavaLine());
           }
  
  
  

---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tomcat-dev-help@jakarta.apache.org


Mime
View raw message