https://issues.apache.org/bugzilla/show_bug.cgi?id=53986

          Priority: P2
            Bug ID: 53986
          Assignee: dev@tomcat.apache.org
           Summary: Comment end tag preceded directly by a dash causes JSP
                    fail compilation
          Severity: normal
    Classification: Unclassified
          Reporter: steve.ra...@yahoo.com
          Hardware: PC
            Status: NEW
           Version: 7.0.32
         Component: Jasper
           Product: Tomcat 7

Created attachment 29466
  --> https://issues.apache.org/bugzilla/attachment.cgi?id=29466&action=edit
JSP file to reproduce compilation error

I have a JSP file that contained a comment line as follows:
<%--- comment ---%>

Such a JSP compiles in Tomcat 7.0.30, but it does not compile in 7.0.32.  I’ve
attached a copy of a test file, which compiles in 7.0.30, but not in 7.0.32. 
The only related change I see in the release notes is
https://issues.apache.org/bugzilla/show_bug.cgi?id=53713.  

>From reading the JSP 2.2 spec, it appears that absent a specific comment about
whitespace, the rules of XML shall apply, which effectively means whitespace is
ignored.  This would seem to indicate this could be a regression introduced in
7.0.32, but since the spec is somewhat vague in the section about comments, 

ERROR 09 Oct 2012 11:15:25,190 [http-bio-8080-exec-8]
[com.liferay.portal.log.Co
mmonsLogImpl.error(52)] org.apache.jasper.JasperException:
/html/portal/layout/v
iew/portlet.jsp (line: 48, column: 6) Unterminated &lt;%-- tag
        at
org.apache.jasper.compiler.DefaultErrorHandler.jspError(DefaultErrorH
andler.java:42)
        at
org.apache.jasper.compiler.ErrorDispatcher.dispatch(ErrorDispatcher.j
ava:408)
        at
org.apache.jasper.compiler.ErrorDispatcher.jspError(ErrorDispatcher.j
ava:133)
        at org.apache.jasper.compiler.Parser.parseComment(Parser.java:615)
        at org.apache.jasper.compiler.Parser.parseElements(Parser.java:1425)
        at org.apache.jasper.compiler.Parser.parse(Parser.java:138)
        at
org.apache.jasper.compiler.ParserController.doParse(ParserController.
java:242)
        at
org.apache.jasper.compiler.ParserController.parse(ParserController.ja
va:102)
        at org.apache.jasper.compiler.Compiler.generateJava(Compiler.java:198)
        at org.apache.jasper.compiler.Compiler.compile(Compiler.java:373)
        at org.apache.jasper.compiler.Compiler.compile(Compiler.java:353)
        at org.apache.jasper.compiler.Compiler.compile(Compiler.java:340)
        at
org.apache.jasper.JspCompilationContext.compile(JspCompilationContext
.java:646)
        at
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper
.java:357)
        at
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:3
90)
        at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:334)
        at javax.servlet.http.HttpServlet.service(HttpServlet.java:722)
        at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Appl
icationFilterChain.java:305)
        at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationF
ilterChain.java:210)
        at com.liferay.filters.strip.StripFilter.doFilter(StripFilter.java:260)

-- 
You are receiving this mail because:
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
For additional commands, e-mail: dev-h...@tomcat.apache.org

Reply via email to