diff --git a/mitmproxy/tools/web/app.py b/mitmproxy/tools/web/app.py index 761c23830..7ea24351a 100644 --- a/mitmproxy/tools/web/app.py +++ b/mitmproxy/tools/web/app.py @@ -308,7 +308,7 @@ class WebSocketEventBroadcaster(tornado.websocket.WebSocketHandler): "utf8", "surrogateescape" ) - for conn in cls.connections: + for conn in cls.connections.copy(): cls.send(conn, message)