OpenBazaar / multiwallet

API based multi-cryptocurrency wallet
MIT License
73 stars 41 forks source link

Release the gofunction in the killed watchdog; Extend write lock #57

Closed placer14 closed 5 years ago

placer14 commented 5 years ago

guardWebsocket is called as a gofunction and cannot release unless done is called. But unfortunately, it's closed after the watchdog barks and ends up living forever. Also extend the write lock to the end of startWebsocket as a precaution to ensure new usage of the client does not cause disconnect before it's done setting up the callbacks.