-
-
Notifications
You must be signed in to change notification settings - Fork 11
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
wire.destroy does not remove the peer from the swarm #7
Comments
|
The use case is a successful TCP connection to a peer that does not answer to the handshake and close the connection. |
In that case this is a bug in Could you open an issue in peer-wire-swarm for a missing |
See the core stream docs for an explanation of the |
So maybe it's a node bug, you can see whatwg/streams#13, where you can notice that the drain method is not totally clear, or other discussions I am participating to regarding node/W3C-WHATWG Streams, where some things remain unclear too. So, until it stabilizes I am not willing to go into more details about streams and the supposed behavior of |
Similar to mafintosh/utp#3
wire.destroy
is callingwire.end()
which will fire thefinish
event but theend
event is never fired sowire.on('end',..)
will never be called and the peer will not be removed from the swarm.Maybe the fix is to add
self.emit('end')
in the function attached to thefinish
eventThe text was updated successfully, but these errors were encountered: