You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tomcat.apache.org by ma...@apache.org on 2012/07/04 22:47:31 UTC

svn commit: r1357398 - in /tomcat/tc6.0.x/trunk: STATUS.txt java/org/apache/catalina/valves/ErrorReportValve.java webapps/docs/changelog.xml

Author: markt
Date: Wed Jul  4 20:47:31 2012
New Revision: 1357398

URL: http://svn.apache.org/viewvc?rev=1357398&view=rev
Log:
Fix https://issues.apache.org/bugzilla/show_bug.cgi?id=53071
Use the message from the Throwable for the error report if none was specified via sendError()

Modified:
    tomcat/tc6.0.x/trunk/STATUS.txt
    tomcat/tc6.0.x/trunk/java/org/apache/catalina/valves/ErrorReportValve.java
    tomcat/tc6.0.x/trunk/webapps/docs/changelog.xml

Modified: tomcat/tc6.0.x/trunk/STATUS.txt
URL: http://svn.apache.org/viewvc/tomcat/tc6.0.x/trunk/STATUS.txt?rev=1357398&r1=1357397&r2=1357398&view=diff
==============================================================================
--- tomcat/tc6.0.x/trunk/STATUS.txt (original)
+++ tomcat/tc6.0.x/trunk/STATUS.txt Wed Jul  4 20:47:31 2012
@@ -137,13 +137,6 @@ PATCHES PROPOSED TO BACKPORT:
        in config/realm.html)
   -1:
   
-* Fix https://issues.apache.org/bugzilla/show_bug.cgi?id=53071
-  Use the message from the Throwable for the error report if none was specified
-  via sendError()
-  http://people.apache.org/~markt/patches/2012-06-11-bug53071-tc6.patch
-  +1: markt, kfujino, kkolinko
-  -1:
-
 
 PATCHES/ISSUES THAT ARE STALLED
 

Modified: tomcat/tc6.0.x/trunk/java/org/apache/catalina/valves/ErrorReportValve.java
URL: http://svn.apache.org/viewvc/tomcat/tc6.0.x/trunk/java/org/apache/catalina/valves/ErrorReportValve.java?rev=1357398&r1=1357397&r2=1357398&view=diff
==============================================================================
--- tomcat/tc6.0.x/trunk/java/org/apache/catalina/valves/ErrorReportValve.java (original)
+++ tomcat/tc6.0.x/trunk/java/org/apache/catalina/valves/ErrorReportValve.java Wed Jul  4 20:47:31 2012
@@ -159,9 +159,15 @@ public class ErrorReportValve
             return;
 
         String message = RequestUtil.filter(response.getMessage());
-        if (message == null)
-            message = "";
-
+        if (message == null) {
+            if (throwable != null) {
+                message = RequestUtil.filter(throwable.getMessage());
+            }
+            if (message == null) {
+                message = "";
+            }
+        }
+        
         // Do nothing if there is no report for the specified status code
         String report = null;
         try {

Modified: tomcat/tc6.0.x/trunk/webapps/docs/changelog.xml
URL: http://svn.apache.org/viewvc/tomcat/tc6.0.x/trunk/webapps/docs/changelog.xml?rev=1357398&r1=1357397&r2=1357398&view=diff
==============================================================================
--- tomcat/tc6.0.x/trunk/webapps/docs/changelog.xml (original)
+++ tomcat/tc6.0.x/trunk/webapps/docs/changelog.xml Wed Jul  4 20:47:31 2012
@@ -154,6 +154,11 @@
         <bug>53057</bug>: Add OpenSSL version number INFO log message when
         initializing. (schultz)
       </fix>
+      <fix>
+        <bug>53071</bug>: Use the message from the Throwable for the error
+        report generated by the <code>ErrorReportValve</code> if none was
+        specified via <code>sendError()</code>. (markt)
+      </fix>
       <update>
         <bug>53230</bug>: Change session managers to throw
         TooManyActiveSessionsException instead of IllegalStateException



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