Bug 62721

Summary: Jasper generates incomplete web.xml 3.1 header
Product: Tomcat 8 Reporter: Chris Bonham <bonhamcm>
Component: JasperAssignee: Tomcat Developers Mailing List <dev>
Severity: normal    
Priority: P2    
Version: 8.5.32   
Target Milestone: ----   
Hardware: Macintosh   
OS: All   

Description Chris Bonham 2018-09-14 11:02:23 UTC
Since 8.5.32, Jasper generates an incomplete web.xml 3.1 header:

<?xml version="1.0" encoding="UTF-8"?>
<web-app xmlns="http://xmlns.jcp.org/xml/ns/javaee"

I believe the cause is the missing backslash on the second line of the jspc.webxml.header properties in LocalStrings.properties:

jspc.webxml.header=<?xml version="1.0" encoding="{0}"?>\n\
<web-app xmlns="http://xmlns.jcp.org/xml/ns/javaee"
\        xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"\n\
\        xsi:schemaLocation="http://xmlns.jcp.org/xml/ns/javaee\n\
\                http://xmlns.jcp.org/xml/ns/javaee/web-app_3_1.xsd"\n\
\        version="3.1"\n\
\        metadata-complete="false">\n\
Automatically created by Apache Tomcat JspC.\n\
Comment 1 Mark Thomas 2018-09-14 13:30:32 UTC
Thanks for the report.

Fixed in:
- trunk for 9.0.13 onwards
- 8.5.x for 8.5.35 onwards
- 7.0.x for 7.0.92 onwards
Comment 2 Chris Bonham 2018-09-14 13:32:53 UTC

I believe the backslash is missing in the Spanish, French and Japanese versions of LocalStrings as well.

Thank you.
Comment 3 Remy Maucherat 2018-09-14 13:36:24 UTC
Correct but Mark fixed that too.