We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 2a4303e commit f0d9d35Copy full SHA for f0d9d35
1 file changed
src/zeroconf/_listener.py
@@ -152,8 +152,7 @@ def _process_datagram_at_time(
152
msg = DNSIncoming(data, addr_port, scope, now)
153
# Move-to-end so a repeat payload refreshes its position and only
154
# cold entries are evicted when the window is full.
155
- if data in recent_packets:
156
- del recent_packets[data]
+ recent_packets.pop(data, None)
157
elif len(recent_packets) >= _RECENT_PACKETS_MAX:
158
del recent_packets[next(iter(recent_packets))]
159
recent_packets[data] = (now, msg.has_qu_question())
0 commit comments