fix segfault when client_body_in_file_only is on, the body is not passed
to upstream, and nginx tries next upstream
This commit is contained in:
parent
8cff9c0e4c
commit
64fb74b910
1 changed files with 5 additions and 2 deletions
|
@ -569,8 +569,11 @@ ngx_http_upstream_connect(ngx_http_request_t *r, ngx_http_upstream_t *u)
|
|||
}
|
||||
}
|
||||
|
||||
if (r->request_body && r->request_body->temp_file && r == r->main) {
|
||||
|
||||
if (r->request_body
|
||||
&& r->request_body->buf
|
||||
&& r->request_body->temp_file
|
||||
&& r == r->main)
|
||||
{
|
||||
/*
|
||||
* the r->request_body->buf can be reused for one request only,
|
||||
* the subrequests should allocate their own temporay bufs
|
||||
|
|
Loading…
Reference in a new issue