mirror of
https://github.com/log4js-node/log4js-node.git
synced 2025-12-08 19:26:01 +00:00
Flush the buffer on 'error'
This commit is contained in:
parent
fc2ba410ad
commit
4565359448
@ -128,7 +128,11 @@ function workerAppender(config) {
|
||||
socket.on('timeout', socket.end.bind(socket));
|
||||
// don't bother listening for 'error', 'close' gets called after that anyway
|
||||
socket.on('close', createSocket);
|
||||
socket.on('error', () => {});
|
||||
socket.on('error', (e) => {
|
||||
debug('connection error', e);
|
||||
canWrite = false;
|
||||
emptyBuffer();
|
||||
});
|
||||
}
|
||||
|
||||
createSocket();
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user