Welcome! Log In Create A New Profile

Advanced

[njs] HTTP: setting default content type in sendHeader().

Dmitry Volyntsev
February 05, 2019 11:42AM
details: https://hg.nginx.org/njs/rev/3b8ea515add6
branches:
changeset: 762:3b8ea515add6
user: Dmitry Volyntsev <xeioex@nginx.com>
date: Tue Feb 05 19:27:24 2019 +0300
description:
HTTP: setting default content type in sendHeader().

diffstat:

nginx/ngx_http_js_module.c | 4 ++++
1 files changed, 4 insertions(+), 0 deletions(-)

diffs (14 lines):

diff -r 4dfc639287f0 -r 3b8ea515add6 nginx/ngx_http_js_module.c
--- a/nginx/ngx_http_js_module.c Tue Feb 05 01:07:45 2019 +0800
+++ b/nginx/ngx_http_js_module.c Tue Feb 05 19:27:24 2019 +0300
@@ -1035,6 +1035,10 @@ ngx_http_js_ext_send_header(njs_vm_t *vm
return NJS_ERROR;
}

+ if (ngx_http_set_content_type(r) != NGX_OK) {
+ return NJS_ERROR;
+ }
+
if (ngx_http_send_header(r) == NGX_ERROR) {
return NJS_ERROR;
}
_______________________________________________
nginx-devel mailing list
nginx-devel@nginx.org
http://mailman.nginx.org/mailman/listinfo/nginx-devel
Subject Author Views Posted

[njs] HTTP: setting default content type in sendHeader().

Dmitry Volyntsev 95 February 05, 2019 11:42AM



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

Online Users

Guests: 82
Record Number of Users: 6 on February 13, 2018
Record Number of Guests: 421 on December 02, 2018
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready