aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorRuslan Ermilov <ru@nginx.com>2015-03-04 08:12:53 +0300
committerRuslan Ermilov <ru@nginx.com>2015-03-04 08:12:53 +0300
commit5e5540f7dccec44b0be89eabe245befb509032fc (patch)
tree35dfe3c46eaea4cbc6d22aea2c61d466811c75d0 /src
parentc238150a57616e4bf7bda8f20fd27901ae323649 (diff)
downloadnginx-5e5540f7dccec44b0be89eabe245befb509032fc.tar.gz
nginx-5e5540f7dccec44b0be89eabe245befb509032fc.zip
Proxy: use an appropriate error on memory allocation failure.
Diffstat (limited to 'src')
-rw-r--r--src/http/modules/ngx_http_proxy_module.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/http/modules/ngx_http_proxy_module.c b/src/http/modules/ngx_http_proxy_module.c
index d7675d468..2409c7ec4 100644
--- a/src/http/modules/ngx_http_proxy_module.c
+++ b/src/http/modules/ngx_http_proxy_module.c
@@ -812,7 +812,7 @@ ngx_http_proxy_handler(ngx_http_request_t *r)
ctx = ngx_pcalloc(r->pool, sizeof(ngx_http_proxy_ctx_t));
if (ctx == NULL) {
- return NGX_ERROR;
+ return NGX_HTTP_INTERNAL_SERVER_ERROR;
}
ngx_http_set_ctx(r, ctx, ngx_http_proxy_module);