2
0
mirror of https://github.com/xcat2/confluent.git synced 2025-02-19 12:05:13 +00:00

Fix Python2 compatibility issue with port forwarder

This commit is contained in:
Jarrod Johnson 2023-06-01 16:50:06 -04:00
parent bc684b82b4
commit 8f1be7c905

View File

@ -119,7 +119,7 @@ def get_port(addr, clientip, sessionid):
newsock.bind(('::', newport, 0, 0))
newsock.listen(50)
break
except OSError as e:
except (socket.error, OSError) as e:
if e.errno == 98:
newport += 1
continue