Merge pull request #117 from TheBlueMatt/2022-08-fix-npe v0.0.110.3
authorMatt Corallo <649246+TheBlueMatt@users.noreply.github.com>
Sat, 3 Sep 2022 22:32:32 +0000 (22:32 +0000)
committerGitHub <noreply@github.com>
Sat, 3 Sep 2022 22:32:32 +0000 (22:32 +0000)
[TS+Java] Ensure we don't try to add a reference from null.

node-net/net.mts

index 58da387d6c59177c363e2777f31091079558caf4..797bc7a7a47907920d9b00039d643cd82cd21133 100644 (file)
@@ -82,6 +82,9 @@ export class NodeLDKNet {
                socket.on("close", function() {
                        this_pm.socket_disconnected(descriptor);
                });
+               socket.on("error", function() {
+                       this_pm.socket_disconnected(descriptor);
+               });
 
                return descriptor;
        }