mirror of
https://github.com/siemens-mobile-hacks/node-serialport-bindings-cpp.git
synced 2026-11-25 18:37:19 +00:00
[unix] fix a bug when poller errors would be unhandled
They will now be handled by the reads and writes that use it.
This commit is contained in:
parent
cc779624db
commit
63c5554fee
1 changed files with 4 additions and 1 deletions
|
|
@ -13,7 +13,10 @@ const EVENTS = {
|
|||
function handleEvent(error, eventFlag) {
|
||||
if (error) {
|
||||
logger('error', error);
|
||||
return this.emit('error', error);
|
||||
this.emit('readable', error);
|
||||
this.emit('writable', error);
|
||||
this.emit('disconnect', error);
|
||||
return;
|
||||
}
|
||||
if (eventFlag & EVENTS.UV_READABLE) {
|
||||
logger('received "readable"');
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue