Author: markt Date: Mon Oct 15 11:42:28 2018 New Revision: 1843900 URL: http://svn.apache.org/viewvc?rev=1843900&view=rev Log: Fix https://bz.apache.org/bugzilla/show_bug.cgi?id=62808 Correct a regression (not included in a release) in the TLD whitespace parsing when the function signature was split over multiple lines.
Modified: tomcat/trunk/java/org/apache/jasper/compiler/Validator.java tomcat/trunk/test/webapp/WEB-INF/test.tld Modified: tomcat/trunk/java/org/apache/jasper/compiler/Validator.java URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/jasper/compiler/Validator.java?rev=1843900&r1=1843899&r2=1843900&view=diff ============================================================================== --- tomcat/trunk/java/org/apache/jasper/compiler/Validator.java (original) +++ tomcat/trunk/java/org/apache/jasper/compiler/Validator.java Mon Oct 15 11:42:28 2018 @@ -423,7 +423,8 @@ class Validator { private static class ValidateVisitor extends Node.Visitor { // Pattern to extract a method name from a full method signature - private static final Pattern METHOD_NAME_PATTERN = Pattern.compile(".*[ \t\n\r]+(.+?)[ \t\n\r]*\\(.*"); + private static final Pattern METHOD_NAME_PATTERN = + Pattern.compile(".*[ \t\n\r]+(.+?)[ \t\n\r]*\\(.*", Pattern.DOTALL); private final PageInfo pageInfo; Modified: tomcat/trunk/test/webapp/WEB-INF/test.tld URL: http://svn.apache.org/viewvc/tomcat/trunk/test/webapp/WEB-INF/test.tld?rev=1843900&r1=1843899&r2=1843900&view=diff ============================================================================== --- tomcat/trunk/test/webapp/WEB-INF/test.tld (original) +++ tomcat/trunk/test/webapp/WEB-INF/test.tld Mon Oct 15 11:42:28 2018 @@ -43,8 +43,11 @@ <function> <name>toArray</name> <function-class>org.apache.el.TesterFunctions</function-class> + <!-- Do not change whitespace in signature below. + It used to test for correctness in o.a.jasper.compiler.Validator. --> <function-signature> - java.lang.String toArray(java.lang.String,java.lang.String) + java.lang.String toArray(java.lang.String, + java.lang.String) </function-signature> </function> --------------------------------------------------------------------- To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org