Better handling of online/offline behavior, socket shutdown (#1593)

* Online/offline: Always stop timer, don't connect if closed

* Sockets: Send our own close event faster, shutdown only on close

Seems that we were too-aggressively disconnecting from all socket
events. Also, we should be able to send our own close event a lot
faster with no ill effects.

* Catch-up libtextsecure changes
This commit is contained in:
Scott Nonnenberg 2017-10-23 14:38:43 -07:00 committed by GitHub
parent 3b810d3196
commit 6a895f0e27
4 changed files with 14 additions and 6 deletions

View file

@ -182,7 +182,7 @@
ev.code = code;
ev.reason = reason;
this.dispatchEvent(ev);
}.bind(this), 10000);
}.bind(this), 1000);
};
};
window.WebSocketResource.prototype = new textsecure.EventTarget();