]> git.kaiwu.me - nginx.git/commitdiff
Merge of r4295:
authorMaxim Dounin <mdounin@mdounin.ru>
Wed, 14 Dec 2011 15:28:13 +0000 (15:28 +0000)
committerMaxim Dounin <mdounin@mdounin.ru>
Wed, 14 Dec 2011 15:28:13 +0000 (15:28 +0000)
Fixed incorrect counting the length of headers in a SCGI request.

src/http/modules/ngx_http_scgi_module.c

index 1feac713bdebf16a1b9757f30b4677938bce4cd8..168f497ce0c2607a28bc4c84a84d30e55db32ff0 100644 (file)
@@ -558,8 +558,10 @@ ngx_http_scgi_create_request(ngx_http_request_t *r)
 
             while (*(uintptr_t *) le.ip) {
                 lcode = *(ngx_http_script_len_code_pt *) le.ip;
-                len += lcode(&le) + 1;
+                len += lcode(&le);
             }
+            len++;
+
             le.ip += sizeof(uintptr_t);
         }
     }