Browse Source
_keep_alive_handler would set up another keep alive after the first one by creating a new threading.Timer object, but Client would only keep track of the first timer object. Thus casing the keep alive to continue running after Client.logout calls cancel() on it's timer object, as it no longer references the actual timer object waiting for the keep alive. Fix by replacing _keep_alive_handler with a threading.Thread subclass that sends keep_alives of the given interval and exits when its stop event is set.pull/3/head
1 changed files with 19 additions and 15 deletions
Loading…
Reference in new issue