Skip to content

Commit 7246a34

Browse files
authored
feat: speed up processing incoming records (#1139)
1 parent 489069a commit 7246a34

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/zeroconf/_handlers.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -489,7 +489,7 @@ def _async_mark_unique_cached_records_older_than_1s_to_expire(
489489
# Since unique is set, all old records with that name, rrtype,
490490
# and rrclass that were received more than one second ago are declared
491491
# invalid, and marked to expire from the cache in one second.
492-
answers_rrset = DNSRRSet(answers)
492+
answers_rrset = set(answers)
493493
for name, type_, class_ in unique_types:
494494
for entry in self.cache.async_all_by_details(name, type_, class_):
495495
if (now - entry.created > _ONE_SECOND) and entry not in answers_rrset:

0 commit comments

Comments
 (0)