details:   http://hg.nginx.org/nginx/rev/15ea84e65d07
branches:  
changeset: 7341:15ea84e65d07
user:      Vladimir Homutov <[email protected]>
date:      Fri Aug 24 12:19:37 2018 +0300
description:
Upstream: fixed request chain traversal (ticket #1618).

The problem does not manifest itself currently, because in case of
non-buffered reading, chain link created by u->create_request method
consists of a single element.

Found by PVS-Studio.

diffstat:

 src/http/ngx_http_upstream.c |  2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diffs (12 lines):

diff -r 70c6b08973a0 -r 15ea84e65d07 src/http/ngx_http_upstream.c
--- a/src/http/ngx_http_upstream.c      Fri Aug 10 21:54:46 2018 +0300
+++ b/src/http/ngx_http_upstream.c      Fri Aug 24 12:19:37 2018 +0300
@@ -2135,7 +2135,7 @@ ngx_http_upstream_send_request_body(ngx_
         out = u->request_bufs;
 
         if (r->request_body->bufs) {
-            for (cl = out; cl->next; cl = out->next) { /* void */ }
+            for (cl = out; cl->next; cl = cl->next) { /* void */ }
             cl->next = r->request_body->bufs;
             r->request_body->bufs = NULL;
         }
_______________________________________________
nginx-devel mailing list
[email protected]
http://mailman.nginx.org/mailman/listinfo/nginx-devel

Reply via email to