]> git.kaiwu.me - nginx.git/commitdiff
r2371 merge:
authorIgor Sysoev <igor@sysoev.ru>
Wed, 1 Apr 2009 16:01:01 +0000 (16:01 +0000)
committerIgor Sysoev <igor@sysoev.ru>
Wed, 1 Apr 2009 16:01:01 +0000 (16:01 +0000)
allow POST without Content-Length

src/http/ngx_http_request.c

index ed48a6efeda5c96b8ce396ea70808dd95dcbb65a..deb283404413e45c5565fc38e03c0f236ff8054b 100644 (file)
@@ -1388,9 +1388,7 @@ ngx_http_process_request_header(ngx_http_request_t *r)
         }
     }
 
-    if (r->method & (NGX_HTTP_POST|NGX_HTTP_PUT)
-        && r->headers_in.content_length_n == -1)
-    {
+    if (r->method & NGX_HTTP_PUT && r->headers_in.content_length_n == -1) {
         ngx_log_error(NGX_LOG_INFO, r->connection->log, 0,
                   "client sent %V method without \"Content-Length\" header",
                   &r->method_name);