Skip to content

Commit d71de28

Browse files
gireeshpunathilMylesBorins
authored andcommitted
test: detect all types of aborts in windows
On Windows, 'aborts' are of 2 types, depending on the context: (i) Forced access violation, if --abort-on-uncaught-exception is on which corresponds to exit code 3221225477 (0xC0000005) (ii) raise(SIGABRT) or abort(), which lands up in CRT library calls which corresponds to exit code 3 PR-URL: #12856 Reviewed-By: Anna Henningsen <[email protected]> Reviewed-By: Sakthipriyan Vairamani <[email protected]> Reviewed-By: Colin Ihrig <[email protected]> Reviewed-By: James M Snell <[email protected]> Reviewed-By: Gibson Fahnestock <[email protected]> Reviewed-By: Benjamin Gruenbaum <[email protected]>
1 parent c01a2d5 commit d71de28

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

test/common/index.js

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -506,10 +506,13 @@ exports.nodeProcessAborted = function nodeProcessAborted(exitCode, signal) {
506506
// or SIGABRT (depending on the compiler).
507507
const expectedSignals = ['SIGILL', 'SIGTRAP', 'SIGABRT'];
508508

509-
// On Windows, v8's base::OS::Abort triggers an access violation,
509+
// On Windows, 'aborts' are of 2 types, depending on the context:
510+
// (i) Forced access violation, if --abort-on-uncaught-exception is on
510511
// which corresponds to exit code 3221225477 (0xC0000005)
512+
// (ii) raise(SIGABRT) or abort(), which lands up in CRT library calls
513+
// which corresponds to exit code 3.
511514
if (exports.isWindows)
512-
expectedExitCodes = [3221225477];
515+
expectedExitCodes = [3221225477, 3];
513516

514517
// When using --abort-on-uncaught-exception, V8 will use
515518
// base::OS::Abort to terminate the process.

0 commit comments

Comments
 (0)