]> git.kaiwu.me - njs.git/commit
Fixed njs_value_to_string() with non-writable dst argument.
authorDmitry Volyntsev <xeioex@nginx.com>
Tue, 30 Aug 2022 04:09:12 +0000 (21:09 -0700)
committerDmitry Volyntsev <xeioex@nginx.com>
Tue, 30 Aug 2022 04:09:12 +0000 (21:09 -0700)
commite53c55e1e20eb8545d0a165c520bf11bd5b14624
tree2b3e7312760a7632e4d303d7765d73217d525f20
parent1ff71a1783403b1abdccc5e56ec6c7ff1cb1fa75
Fixed njs_value_to_string() with non-writable dst argument.

njs_arg(args, nargs, N) returns a pointer to Nth argument OR a pointer
to undefined constant value njs_value_undefined if N >= nargs.
njs_value_to_string() writes to a dst argument its result.
This means that it is incorrect to use value of njs_arg() directly
as a second argument to njs_value_to_string().

This closes #570 issue on Github.
external/njs_webcrypto_module.c
src/njs_number.c
src/njs_symbol.c
src/test/njs_unit_test.c