mirror of
https://github.com/ether/etherpad-lite.git
synced 2025-01-19 22:23:33 +01:00
Merge pull request #1675 from ether/fix/process-uncaughtException-event-handler-leak
Don't leak event listeners for process:uncaughtException
This commit is contained in:
commit
c6041bf0c2
1 changed files with 2 additions and 3 deletions
|
@ -28,6 +28,7 @@ exports.gracefulShutdown = function(err) {
|
||||||
}, 3000);
|
}, 3000);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
process.on('uncaughtException', exports.gracefulShutdown);
|
||||||
|
|
||||||
exports.expressCreateServer = function (hook_name, args, cb) {
|
exports.expressCreateServer = function (hook_name, args, cb) {
|
||||||
exports.app = args.app;
|
exports.app = args.app;
|
||||||
|
@ -47,6 +48,4 @@ exports.expressCreateServer = function (hook_name, args, cb) {
|
||||||
//https://github.com/joyent/node/issues/1553
|
//https://github.com/joyent/node/issues/1553
|
||||||
process.on('SIGINT', exports.gracefulShutdown);
|
process.on('SIGINT', exports.gracefulShutdown);
|
||||||
}
|
}
|
||||||
|
|
||||||
process.on('uncaughtException', exports.gracefulShutdown);
|
|
||||||
}
|
}
|
Loading…
Reference in a new issue