Welcome! Log In Create A New Profile

Advanced

[nginx] Fixed request finalization in ngx_http_index_handler().

December 23, 2019 10:46AM
details: https://hg.nginx.org/nginx/rev/e55e28e6998f
branches:
changeset: 7603:e55e28e6998f
user: Ruslan Ermilov <ru@nginx.com>
date: Mon Dec 16 15:19:01 2019 +0300
description:
Fixed request finalization in ngx_http_index_handler().

Returning 500 instead of NGX_ERROR is preferable here because
header has not yet been sent to the client.

diffstat:

src/http/modules/ngx_http_index_module.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)

diffs (12 lines):

diff -r b399246ea45d -r e55e28e6998f src/http/modules/ngx_http_index_module.c
--- a/src/http/modules/ngx_http_index_module.c Mon Dec 16 15:19:01 2019 +0300
+++ b/src/http/modules/ngx_http_index_module.c Mon Dec 16 15:19:01 2019 +0300
@@ -163,7 +163,7 @@

name = ngx_http_map_uri_to_path(r, &path, &root, reserve);
if (name == NULL) {
- return NGX_ERROR;
+ return NGX_HTTP_INTERNAL_SERVER_ERROR;
}

allocated = path.data + path.len - name;
_______________________________________________
nginx-devel mailing list
nginx-devel@nginx.org
http://mailman.nginx.org/mailman/listinfo/nginx-devel
Subject Author Views Posted

[nginx] Fixed request finalization in ngx_http_index_handler().

ru@nginx.com 466 December 23, 2019 10:46AM



Sorry, you do not have permission to post/reply in this forum.

Online Users

Guests: 303
Record Number of Users: 8 on April 13, 2023
Record Number of Guests: 421 on December 02, 2018
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready