webtorrent / bittorrent-tracker

🌊 Simple, robust, BitTorrent tracker (client & server) implementation
https://webtorrent.io
MIT License
1.78k stars 319 forks source link

Don't return if not listening (websockets) #79

Closed Chocobozzz closed 9 years ago

Chocobozzz commented 9 years ago

First of all, thanks for you amazing job :)

I noticed one issue with this line: https://github.com/feross/bittorrent-tracker/blob/master/server.js#L302

I run bittorent-tracker in an express application with the ws module and I use onWebSocketConnection to redirect ws request to the bittorent-tracker server. So the tracker never listens, and thus it returns at this line. If I remove it, all work as expected.

feross commented 9 years ago

Thanks for pointing this out. Fixed and released as 4.4.5.

Chocobozzz commented 9 years ago

Great thanks :)