1
0
mirror of https://github.com/apache/httpd.git synced 2025-11-05 05:30:39 +03:00

Don't keepalive when we send a non-100 response while Client is expecting 100

and may be feeding us continuation data.
PR 47087


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@888310 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Nick Kew
2009-12-08 10:22:56 +00:00
parent b310db9324
commit 33b33d1987
4 changed files with 24 additions and 0 deletions

View File

@@ -1682,6 +1682,7 @@ AP_DECLARE(void) ap_send_interim_response(request_rec *r, int send_headers)
{
hdr_ptr x;
char *status_line = NULL;
request_rec *rr;
if (r->proto_num < 1001) {
/* don't send interim response to HTTP/1.0 Client */
@@ -1701,6 +1702,14 @@ AP_DECLARE(void) ap_send_interim_response(request_rec *r, int send_headers)
return;
}
/* if we send an interim response, we're no longer in a state of
* expecting one. Also, this could feasibly be in a subrequest,
* so we need to propagate the fact that we responded.
*/
for (rr = r; rr != NULL; rr = rr->main) {
rr->expecting_100 = 0;
}
status_line = apr_pstrcat(r->pool, AP_SERVER_PROTOCOL, " ", r->status_line, CRLF, NULL);
ap_xlate_proto_to_ascii(status_line, strlen(status_line));