Closed tiye closed 3 years ago
Can you post your code? I suspect you are busy-looping on EventHub::next_event()
. I recommended using either EventHub::poll_event()
, or sleeping in your loop.
I've actually just noticed that the example in the readme uses next_event()
instead of poll_event()
which would be more correct in this case. I'll update that example, thanks for pointing this out :)
I've fixed the example in https://github.com/Flying-Toast/simple-websockets/commit/e543bcd6d8c00fd08189411e767133e9b8251a98, could you take a look at the change and see if your code is doing the same thing? Please re-open the issue if you're still having issues.
Looks good now, cheers~
lack of sleep?