mirror of https://github.com/nodejs/node.git
dgram: defer send error to next tick
parent
defa637378
commit
3502e45b6c
|
@ -189,7 +189,10 @@ Socket.prototype.send = function(buffer,
|
|||
}
|
||||
else {
|
||||
// don't emit as error, dgram_legacy.js compatibility
|
||||
callback(errnoException(errno, 'send'));
|
||||
var err = errnoException(errno, 'send');
|
||||
process.nextTick(function() {
|
||||
callback(err);
|
||||
});
|
||||
}
|
||||
}
|
||||
});
|
||||
|
|
Loading…
Reference in New Issue