aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/http/modules/ngx_http_fastcgi_module.c14
-rw-r--r--src/http/modules/ngx_http_proxy_module.c14
-rw-r--r--src/http/ngx_http_upstream.c2
3 files changed, 15 insertions, 15 deletions
diff --git a/src/http/modules/ngx_http_fastcgi_module.c b/src/http/modules/ngx_http_fastcgi_module.c
index 7b799c516..00384a1af 100644
--- a/src/http/modules/ngx_http_fastcgi_module.c
+++ b/src/http/modules/ngx_http_fastcgi_module.c
@@ -887,7 +887,7 @@ ngx_http_fastcgi_process_header(ngx_http_request_t *r)
if (f == NULL) {
f = ngx_pcalloc(r->pool, sizeof(ngx_http_fastcgi_ctx_t));
if (f == NULL) {
- return NGX_HTTP_INTERNAL_SERVER_ERROR;
+ return NGX_ERROR;
}
ngx_http_set_ctx(r, f, ngx_http_fastcgi_module);
@@ -1063,7 +1063,7 @@ ngx_http_fastcgi_process_header(ngx_http_request_t *r)
h = ngx_list_push(&u->headers_in.headers);
if (h == NULL) {
- return NGX_HTTP_INTERNAL_SERVER_ERROR;
+ return NGX_ERROR;
}
if (f->split_parts && f->split_parts->nelts) {
@@ -1077,7 +1077,7 @@ ngx_http_fastcgi_process_header(ngx_http_request_t *r)
p = ngx_palloc(r->pool, size);
if (p == NULL) {
- return NGX_HTTP_INTERNAL_SERVER_ERROR;
+ return NGX_ERROR;
}
buf.pos = p;
@@ -1105,7 +1105,7 @@ ngx_http_fastcgi_process_header(ngx_http_request_t *r)
h->lowcase_key = ngx_palloc(r->pool, h->key.len);
if (h->lowcase_key == NULL) {
- return NGX_HTTP_INTERNAL_SERVER_ERROR;
+ return NGX_ERROR;
}
} else {
@@ -1117,7 +1117,7 @@ ngx_http_fastcgi_process_header(ngx_http_request_t *r)
h->key.len + 1 + h->value.len + 1
+ h->key.len);
if (h->key.data == NULL) {
- return NGX_HTTP_INTERNAL_SERVER_ERROR;
+ return NGX_ERROR;
}
h->value.data = h->key.data + h->key.len + 1;
@@ -1145,7 +1145,7 @@ ngx_http_fastcgi_process_header(ngx_http_request_t *r)
h->lowcase_key, h->key.len);
if (hh && hh->handler(r, h, hh->offset) != NGX_OK) {
- return NGX_HTTP_INTERNAL_SERVER_ERROR;
+ return NGX_ERROR;
}
ngx_log_debug2(NGX_LOG_DEBUG_HTTP, r->connection->log, 0,
@@ -1238,7 +1238,7 @@ ngx_http_fastcgi_process_header(ngx_http_request_t *r)
f->split_parts = ngx_array_create(r->pool, 1,
sizeof(ngx_http_fastcgi_split_part_t));
if (f->split_parts == NULL) {
- return NGX_HTTP_INTERNAL_SERVER_ERROR;
+ return NGX_ERROR;
}
}
diff --git a/src/http/modules/ngx_http_proxy_module.c b/src/http/modules/ngx_http_proxy_module.c
index 5f8b27803..24da70dcc 100644
--- a/src/http/modules/ngx_http_proxy_module.c
+++ b/src/http/modules/ngx_http_proxy_module.c
@@ -959,7 +959,7 @@ ngx_http_proxy_process_status_line(ngx_http_request_t *r)
ctx = ngx_http_get_module_ctx(r, ngx_http_proxy_module);
if (ctx == NULL) {
- return NGX_HTTP_INTERNAL_SERVER_ERROR;
+ return NGX_ERROR;
}
rc = ngx_http_proxy_parse_status_line(r, ctx);
@@ -994,7 +994,7 @@ ngx_http_proxy_process_status_line(ngx_http_request_t *r)
u->headers_in.status_line.data = ngx_palloc(r->pool,
u->headers_in.status_line.len);
if (u->headers_in.status_line.data == NULL) {
- return NGX_HTTP_INTERNAL_SERVER_ERROR;
+ return NGX_ERROR;
}
ngx_memcpy(u->headers_in.status_line.data, ctx->status_start,
@@ -1239,7 +1239,7 @@ ngx_http_proxy_process_header(ngx_http_request_t *r)
h = ngx_list_push(&r->upstream->headers_in.headers);
if (h == NULL) {
- return NGX_HTTP_INTERNAL_SERVER_ERROR;
+ return NGX_ERROR;
}
h->hash = r->header_hash;
@@ -1250,7 +1250,7 @@ ngx_http_proxy_process_header(ngx_http_request_t *r)
h->key.data = ngx_palloc(r->pool,
h->key.len + 1 + h->value.len + 1 + h->key.len);
if (h->key.data == NULL) {
- return NGX_HTTP_INTERNAL_SERVER_ERROR;
+ return NGX_ERROR;
}
h->value.data = h->key.data + h->key.len + 1;
@@ -1272,7 +1272,7 @@ ngx_http_proxy_process_header(ngx_http_request_t *r)
h->lowcase_key, h->key.len);
if (hh && hh->handler(r, h, hh->offset) != NGX_OK) {
- return NGX_HTTP_INTERNAL_SERVER_ERROR;
+ return NGX_ERROR;
}
ngx_log_debug2(NGX_LOG_DEBUG_HTTP, r->connection->log, 0,
@@ -1297,7 +1297,7 @@ ngx_http_proxy_process_header(ngx_http_request_t *r)
if (r->upstream->headers_in.server == NULL) {
h = ngx_list_push(&r->upstream->headers_in.headers);
if (h == NULL) {
- return NGX_HTTP_INTERNAL_SERVER_ERROR;
+ return NGX_ERROR;
}
h->hash = ngx_hash(ngx_hash(ngx_hash(ngx_hash(
@@ -1313,7 +1313,7 @@ ngx_http_proxy_process_header(ngx_http_request_t *r)
if (r->upstream->headers_in.date == NULL) {
h = ngx_list_push(&r->upstream->headers_in.headers);
if (h == NULL) {
- return NGX_HTTP_INTERNAL_SERVER_ERROR;
+ return NGX_ERROR;
}
h->hash = ngx_hash(ngx_hash(ngx_hash('d', 'a'), 't'), 'e');
diff --git a/src/http/ngx_http_upstream.c b/src/http/ngx_http_upstream.c
index 3d7249921..48158a4e5 100644
--- a/src/http/ngx_http_upstream.c
+++ b/src/http/ngx_http_upstream.c
@@ -1158,7 +1158,7 @@ ngx_http_upstream_process_header(ngx_event_t *rev)
return;
}
- if (rc == NGX_ERROR || rc == NGX_HTTP_INTERNAL_SERVER_ERROR) {
+ if (rc == NGX_ERROR) {
ngx_http_upstream_finalize_request(r, u,
NGX_HTTP_INTERNAL_SERVER_ERROR);
return;