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/08/10 23:36:54 UTC
svn commit: r1371824 - in /tomcat/tc7.0.x/trunk: ./
java/org/apache/catalina/core/StandardHostValve.java
webapps/docs/changelog.xml
Author: markt
Date: Fri Aug 10 21:36:54 2012
New Revision: 1371824
URL: http://svn.apache.org/viewvc?rev=1371824&view=rev
Log:
Need to reset content length as well to ensure custom error page is not truncated.
Modified:
tomcat/tc7.0.x/trunk/ (props changed)
tomcat/tc7.0.x/trunk/java/org/apache/catalina/core/StandardHostValve.java
tomcat/tc7.0.x/trunk/webapps/docs/changelog.xml
Propchange: tomcat/tc7.0.x/trunk/
------------------------------------------------------------------------------
Merged /tomcat/trunk:r1371823
Modified: tomcat/tc7.0.x/trunk/java/org/apache/catalina/core/StandardHostValve.java
URL: http://svn.apache.org/viewvc/tomcat/tc7.0.x/trunk/java/org/apache/catalina/core/StandardHostValve.java?rev=1371824&r1=1371823&r2=1371824&view=diff
==============================================================================
--- tomcat/tc7.0.x/trunk/java/org/apache/catalina/core/StandardHostValve.java (original)
+++ tomcat/tc7.0.x/trunk/java/org/apache/catalina/core/StandardHostValve.java Fri Aug 10 21:36:54 2012
@@ -453,6 +453,7 @@ final class StandardHostValve extends Va
} else {
// Reset the response (keeping the real error code and message)
response.resetBuffer(true);
+ response.setContentLength(-1);
rd.forward(request.getRequest(), response.getResponse());
Modified: tomcat/tc7.0.x/trunk/webapps/docs/changelog.xml
URL: http://svn.apache.org/viewvc/tomcat/tc7.0.x/trunk/webapps/docs/changelog.xml?rev=1371824&r1=1371823&r2=1371824&view=diff
==============================================================================
--- tomcat/tc7.0.x/trunk/webapps/docs/changelog.xml (original)
+++ tomcat/tc7.0.x/trunk/webapps/docs/changelog.xml Fri Aug 10 21:36:54 2012
@@ -116,6 +116,10 @@
Document the constants that were added to the
<code>RequestDispatcher</code> interface in Servlet 3.0. (kkolinko)
</scode>
+ <fix>
+ Ensure custom error pages are not truncated if the page that triggered
+ the error set a content length header. (markt)
+ </fix>
</changelog>
</subsection>
<subsection name="Coyote">
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org