]> git.kaiwu.me - njs.git/commit
Fixed undefined behaviour in njs_number_to_integer().
authorDmitry Volyntsev <xeioex@nginx.com>
Mon, 24 May 2021 10:51:47 +0000 (10:51 +0000)
committerDmitry Volyntsev <xeioex@nginx.com>
Mon, 24 May 2021 10:51:47 +0000 (10:51 +0000)
commit8c83899e1ed6933aebb917d190d10a0def788e63
tree19fefd46c34d972bb2f3448a38850aa2f9bf37c4
parent846389dd665a3b69b2ff88cab282d48c0209bbb1
Fixed undefined behaviour in njs_number_to_integer().

C11: 6.3.1.4
... If the value of the integral part cannot be represented by the
integer type, the behavior is undefined.

Found by OSS-Fuzz.
src/njs_number.h
src/test/njs_unit_test.c