Author: remy.maucherat(a)jboss.com
Date: 2012-10-02 12:10:35 -0400 (Tue, 02 Oct 2012)
New Revision: 2096
Modified:
branches/7.0.x/java/org/apache/catalina/core/StandardHostValve.java
Log:
Port default error page (now clarified). Also port a minor additional patch.
Modified: branches/7.0.x/java/org/apache/catalina/core/StandardHostValve.java
===================================================================
--- branches/7.0.x/java/org/apache/catalina/core/StandardHostValve.java 2012-10-02
16:08:29 UTC (rev 2095)
+++ branches/7.0.x/java/org/apache/catalina/core/StandardHostValve.java 2012-10-02
16:10:35 UTC (rev 2096)
@@ -434,6 +434,10 @@
return;
ErrorPage errorPage = context.findErrorPage(statusCode);
+ if (errorPage == null) {
+ // Look for a default error page
+ errorPage = context.findErrorPage(0);
+ }
if (errorPage != null) {
response.setAppCommitted(false);
request.setAttribute(RequestDispatcher.ERROR_STATUS_CODE,
@@ -524,6 +528,7 @@
// Reset the response (keeping the real error code and message)
response.resetBuffer(true);
+ response.setContentLength(-1);
// Forward control to the specified location
ServletContext servletContext =
Show replies by date