]> git.kaiwu.me - nginx.git/commitdiff
Gzip static: use an appropriate error on memory allocation failure.
authorSergey Kandaurov <pluknet@nginx.com>
Thu, 20 Apr 2017 15:26:38 +0000 (18:26 +0300)
committerSergey Kandaurov <pluknet@nginx.com>
Thu, 20 Apr 2017 15:26:38 +0000 (18:26 +0300)
src/http/modules/ngx_http_gzip_static_module.c

index 1d87cd4eff40ee806a9f4c45d1a11c02386cfaf3..7652a9af3effbadb1e18892c28bc1e0d7dac3b82 100644 (file)
@@ -238,7 +238,7 @@ ngx_http_gzip_static_handler(ngx_http_request_t *r)
 
     h = ngx_list_push(&r->headers_out.headers);
     if (h == NULL) {
-        return NGX_ERROR;
+        return NGX_HTTP_INTERNAL_SERVER_ERROR;
     }
 
     h->hash = 1;