mirror of
https://github.com/sshuttle/sshuttle.git
synced 2025-02-12 08:29:15 +01:00
Fixed dictionary changed size during iteration
The removal loop should probably be outside the iteration loop.
This commit is contained in:
parent
c61984088b
commit
117afc7a68
@ -334,8 +334,8 @@ def main(latency_control):
|
||||
debug3('expiring dnsreqs channel=%d\n' % channel)
|
||||
remove.append(channel)
|
||||
h.ok = False
|
||||
for channel in remove:
|
||||
del dnshandlers[channel]
|
||||
for channel in remove:
|
||||
del dnshandlers[channel]
|
||||
if udphandlers:
|
||||
remove = []
|
||||
for channel, h in udphandlers.items():
|
||||
@ -343,5 +343,5 @@ def main(latency_control):
|
||||
debug3('expiring UDP channel=%d\n' % channel)
|
||||
remove.append(channel)
|
||||
h.ok = False
|
||||
for channel in remove:
|
||||
del udphandlers[channel]
|
||||
for channel in remove:
|
||||
del udphandlers[channel]
|
||||
|
Loading…
Reference in New Issue
Block a user