diff options
author | coletdjnz <coletdjnz@protonmail.com> | 2024-11-24 10:30:00 +1300 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-11-24 10:30:00 +1300 |
commit | c7316373c0a886f65a07a51e50ee147bb3294c85 (patch) | |
tree | 99e54dc9afb52642dd3db5bccf28e1b2f7b5a20f /test/test_socks.py | |
parent | e0f1ae813b36e783e2348ba2a1566e12f5cd8f6e (diff) |
[rh:websockets] Support websockets 14.0+ (#11616)
Authored by: coletdjnz
Diffstat (limited to 'test/test_socks.py')
-rw-r--r-- | test/test_socks.py | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/test/test_socks.py b/test/test_socks.py index 68af19d0c..f601fc8a5 100644 --- a/test/test_socks.py +++ b/test/test_socks.py @@ -216,7 +216,9 @@ class SocksWebSocketTestRequestHandler(SocksTestRequestHandler): protocol = websockets.ServerProtocol() connection = websockets.sync.server.ServerConnection(socket=self.request, protocol=protocol, close_timeout=0) connection.handshake() - connection.send(json.dumps(self.socks_info)) + for message in connection: + if message == 'socks_info': + connection.send(json.dumps(self.socks_info)) connection.close() |