esp8266/modules/webrepl: Enforce only one concurrent WebREPL connection.
Concurrent WebREPL connections were never supported, now actually check for this.
This commit is contained in:
parent
84679e0c06
commit
3f251efb9b
@ -31,6 +31,10 @@ def setup_conn(port, accept_handler):
|
||||
def accept_conn(listen_sock):
|
||||
global client_s
|
||||
cl, remote_addr = listen_sock.accept()
|
||||
if uos.dupterm():
|
||||
print("\nConcurrent WebREPL connection from", remote_addr, "rejected")
|
||||
cl.close()
|
||||
return
|
||||
print("\nWebREPL connection from:", remote_addr)
|
||||
client_s = cl
|
||||
websocket_helper.server_handshake(cl)
|
||||
|
Loading…
Reference in New Issue
Block a user