Skip to content
Commit fcfce9d9 authored by Justin Erenkrantz's avatar Justin Erenkrantz
Browse files

Fix the case where if there is no ErrorDocument specified for an error,

the error would be sent to the client *twice* because both the filter
and the core would trigger error responses.

The problem is that the filters have already handled some errors (say 413)
and due to the ap_get_client_block API, the error was morphed into 400.
Therefore, ap_discard_request_body must use brigades directly rather than
the ap_get_client_block API so that any potential errors are not dropped.

The special value AP_FILTER_ERROR indicates that the lower level has
already dealt with this problem (ap_die() will realize this).  Otherwise,
we'll error with HTTP_BAD_REQUEST and ap_die() will take it from there.

This also prevents needless memory copies when we are just going to
discard it anyway.

Thanks to Cliff Woolley who found this wacky problem.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@95424 13f79535-47bb-0310-9956-ffa450edef68
parent 4c4945f6
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment