Skip to content

Commit

Permalink
Debug logging: disconnect errors
Browse files Browse the repository at this point in the history
  • Loading branch information
Jonas authored and sweetpi committed Oct 5, 2014
1 parent 31c5aca commit 81be32c
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion serialport.js
Original file line number Diff line number Diff line change
Expand Up @@ -371,9 +371,10 @@ function SerialPortFactory() {

try {
factory.SerialPortBinding.close(fd, function (err) {
console.log('Disconnect completed' + (err ? ' with error' : ''), err);
});
} catch (e) {
//handle silently as we are just cleaning up the OS.
console.log('Disconnect failed with exception', e);
}

self.removeAllListeners();
Expand Down

0 comments on commit 81be32c

Please sign in to comment.