Log uncaught exceptions on the socket server
Reviewed By: @frantic Differential Revision: D2462114
This commit is contained in:
parent
f762a55abd
commit
8f5b2ccbe0
|
@ -37,6 +37,11 @@ class SocketServer {
|
|||
});
|
||||
});
|
||||
|
||||
process.on('uncaughtException', (error) => {
|
||||
debug('uncaught error', error);
|
||||
setImmediate(() => process.exit(1));
|
||||
});
|
||||
|
||||
this._numConnections = 0;
|
||||
this._server.on('connection', (sock) => this._handleConnection(sock));
|
||||
|
||||
|
|
Loading…
Reference in New Issue