diff src/http/modules/ngx_http_static_module.c @ 6973:99934aade555

Use ngx_calloc_buf() where appropriate.
author Ruslan Ermilov <ru@nginx.com>
date Wed, 12 Apr 2017 22:21:04 +0300
parents a72886067bbb
children 0cdee26605f3
line wrap: on
line diff
--- a/src/http/modules/ngx_http_static_module.c
+++ b/src/http/modules/ngx_http_static_module.c
@@ -233,7 +233,7 @@ ngx_http_static_handler(ngx_http_request
 
     /* we need to allocate all before the header would be sent */
 
-    b = ngx_pcalloc(r->pool, sizeof(ngx_buf_t));
+    b = ngx_calloc_buf(r->pool);
     if (b == NULL) {
         return NGX_HTTP_INTERNAL_SERVER_ERROR;
     }