diff options
Diffstat (limited to 'test/parallel/test-cluster-uncaught-exception.js')
-rw-r--r-- | test/parallel/test-cluster-uncaught-exception.js | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/test/parallel/test-cluster-uncaught-exception.js b/test/parallel/test-cluster-uncaught-exception.js index 04eac2e8ce..1f04b71f01 100644 --- a/test/parallel/test-cluster-uncaught-exception.js +++ b/test/parallel/test-cluster-uncaught-exception.js @@ -23,8 +23,7 @@ if (isTestRunner) { master.on('exit', function(code) { exitCode = code; }); -} -else if (cluster.isMaster) { +} else if (cluster.isMaster) { process.on('uncaughtException', function() { process.nextTick(function() { process.exit(MAGIC_EXIT_CODE); @@ -33,7 +32,6 @@ else if (cluster.isMaster) { cluster.fork(); throw new Error('kill master'); -} -else { // worker +} else { // worker process.exit(); } |