ASF Bugzilla – Attachment 20299 Details for
Bug 42409
Extra response headers not sent when using custom error page
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
[patch]
call "response.resetBuffer()" instead of "response.reset(statusCode, message)"
42409.patch (text/plain), 1.70 KB, created by
Shiva Kumar H R
on 2007-05-31 07:53:26 UTC
(
hide
)
Description:
call "response.resetBuffer()" instead of "response.reset(statusCode, message)"
Filename:
MIME Type:
Creator:
Shiva Kumar H R
Created:
2007-05-31 07:53:26 UTC
Size:
1.70 KB
patch
obsolete
>Index: StandardHostValve.java >=================================================================== >--- StandardHostValve.java (revision 543064) >+++ StandardHostValve.java (working copy) >@@ -320,13 +320,13 @@ > ErrorPage errorPage = context.findErrorPage(statusCode); > if (errorPage != null) { > response.setAppCommitted(false); >- request.setAttribute(Globals.STATUS_CODE_ATTR, >+ /*request.setAttribute(Globals.STATUS_CODE_ATTR, > new Integer(statusCode)); > > String message = RequestUtil.filter(response.getMessage()); > if (message == null) > message = ""; >- request.setAttribute(Globals.ERROR_MESSAGE_ATTR, message); >+ request.setAttribute(Globals.ERROR_MESSAGE_ATTR, message);*/ > request.setAttribute > (ApplicationFilterFactory.DISPATCHER_REQUEST_PATH_ATTR, > errorPage.getLocation()); >@@ -409,12 +409,13 @@ > // Reset the response if possible (else IllegalStateException) > //hres.reset(); > // Reset the response (keeping the real error code and message) >- Integer statusCodeObj = >+ /*Integer statusCodeObj = > (Integer) request.getAttribute(Globals.STATUS_CODE_ATTR); > int statusCode = statusCodeObj.intValue(); > String message = > (String) request.getAttribute(Globals.ERROR_MESSAGE_ATTR); >- response.reset(statusCode, message); >+ response.reset(statusCode, message);*/ >+ response.resetBuffer(); > > // Forward control to the specified location > ServletContext servletContext =
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 42409
:
20297
|
20298
| 20299