posicks / mdnsjava

Multicast DNS (mDNS) [RFC 6762] & DNS-Based Service Discovery (DNS-SD) [RFC6763] in Java
http://posicks.github.io/mdnsjava/
110 stars 43 forks source link

Concurrency issue in Lookup #6

Closed posicks closed 8 years ago

posicks commented 8 years ago

java.util.ConcurrentModificationException at java.util.LinkedList$ListItr.checkForComodification(LinkedList.java:966) at java.util.LinkedList$ListItr.next(LinkedList.java:888) at net.posick.mDNS.Lookup.lookupRecords(Lookup.java:271) at net.posick.mDNS.Lookup.lookupServices(Lookup.java:325) at net.posick.mDNS.MulticastDNSService$Register.register(MulticastDNSService.java:364) at net.posick.mDNS.MulticastDNSService.register(MulticastDNSService.java:867)

posicks commented 8 years ago

Changed Lookup to use a ConcurrentLinkedQueue to resolve concurrency issues.

hakanai commented 5 years ago

v2.2.0 presumably has the fix for this, but is it safe to upgrade? There is some scary text on the readme saying to use the older snapshots still.