Break reference cycle between WebSocketHandler and WebSocketProtocol on close.
This isn't strictly necessary, but it allows the refcounting CPython GC to clean things up without waiting for a full GC. Closes #382.
This commit is contained in:
parent
6e00a75a95
commit
3e4b4cac66
|
@ -210,6 +210,7 @@ class WebSocketHandler(tornado.web.RequestHandler):
|
||||||
Once the close handshake is successful the socket will be closed.
|
Once the close handshake is successful the socket will be closed.
|
||||||
"""
|
"""
|
||||||
self.ws_connection.close()
|
self.ws_connection.close()
|
||||||
|
self.ws_connection = None
|
||||||
|
|
||||||
def allow_draft76(self):
|
def allow_draft76(self):
|
||||||
"""Override to enable support for the older "draft76" protocol.
|
"""Override to enable support for the older "draft76" protocol.
|
||||||
|
|
Loading…
Reference in New Issue