From 544bd16d94408350d335fdc480eeccf6ecbbffbf Mon Sep 17 00:00:00 2001 From: Antoine du Hamel Date: Fri, 19 Mar 2021 11:22:49 +0100 Subject: [PATCH] fixup! tty: validate file descriptor to avoid int32 overflow --- test/pseudo-tty/test-tty-isatty.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/pseudo-tty/test-tty-isatty.js b/test/pseudo-tty/test-tty-isatty.js index ca84144946104c..ad81a4c6eff92b 100644 --- a/test/pseudo-tty/test-tty-isatty.js +++ b/test/pseudo-tty/test-tty-isatty.js @@ -10,7 +10,7 @@ strictEqual(isatty(2), true, 'stderr reported to not be a tty, but it is'); strictEqual(isatty(-1), false, '-1 reported to be a tty, but it is not'); strictEqual(isatty(55555), false, '55555 reported to be a tty, but it is not'); -strictEqual(isatty(2**31), false, '2^31 reported to be a tty, but it is not'); +strictEqual(isatty(2 ** 31), false, '2^31 reported to be a tty, but it is not'); strictEqual(isatty(1.1), false, '1.1 reported to be a tty, but it is not'); strictEqual(isatty('1'), false, '\'1\' reported to be a tty, but it is not'); strictEqual(isatty({}), false, '{} reported to be a tty, but it is not');