[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]
[tor-commits] [snowflake/master] Close connections before unloading
commit cf1b0a49f13f2550cad1b32ef4e4820b4c26bcf1
Author: Arlo Breault <arlolra@xxxxxxxxx>
Date: Fri Mar 18 14:22:34 2016 -0700
Close connections before unloading
Noticed a long delay after the window closed before the datachannel
timed out.
2016/03/18 13:53:16 Traffic Bytes (in|out): 202576 | 8087
2016/03/18 13:58:10 WebRTC: DataChannel.OnClose [remotely]
---
proxy/snowflake.coffee | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/proxy/snowflake.coffee b/proxy/snowflake.coffee
index eff96de..7e26481 100644
--- a/proxy/snowflake.coffee
+++ b/proxy/snowflake.coffee
@@ -226,4 +226,8 @@ window.onbeforeunload = ->
return CONFIRMATION_MESSAGE
null
+window.onunload = ->
+ pair.close() for pair in snowflake.proxyPairs
+ null
+
window.onload = init if window
_______________________________________________
tor-commits mailing list
tor-commits@xxxxxxxxxxxxxxxxxxxx
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-commits