]> git.kaiwu.me - njs.git/commit
Fixed exception handling.
authorDmitry Volyntsev <xeioex@nginx.com>
Fri, 17 Nov 2017 15:55:07 +0000 (18:55 +0300)
committerDmitry Volyntsev <xeioex@nginx.com>
Fri, 17 Nov 2017 15:55:07 +0000 (18:55 +0300)
commit575be638c4beff4cae3dec74a6c4ae0692bde18b
treecf5024f465d05935c806f4ad15f86a0adb4b5611
parent60a43c5e5d1cc279fc5871aeb56c4338da50c309
Fixed exception handling.

njs_vm_exception() is removed and combined with njs_vm_retval().
vm->exception is removed either, exceptions are now stored in
vm->retval.  It simplifies the client logic, because previously
njs_vm_exception() had to be called if njs_vm_retval() fails.
Additonally, stack traces are now appended to the retval if an exception
happens.
19 files changed:
nginx/ngx_http_js_module.c
nginx/ngx_stream_js_module.c
njs/njs.c
njs/njs_error.c
njs/njs_function.c
njs/njs_generator.c
njs/njs_parser.c
njs/njs_parser.h
njs/njs_parser_expression.c
njs/njs_regexp.c
njs/njs_variable.c
njs/njs_vm.c
njs/njs_vm.h
njs/njscript.c
njs/njscript.h
njs/test/njs_benchmark.c
njs/test/njs_expect_test.exp
njs/test/njs_interactive_test.c
njs/test/njs_unit_test.c