mirror of
https://github.com/grishka/NearDrop.git
synced 2026-04-03 01:36:15 +02:00
Ignore the localhost MDNS service
This commit is contained in:
@@ -299,6 +299,14 @@ public class NearbyConnectionManager : NSObject, NetServiceDelegate, InboundNear
|
||||
#if DEBUG
|
||||
print("found service \(service)")
|
||||
#endif
|
||||
for interface in service.interfaces{
|
||||
if case .loopback=interface.type{
|
||||
#if DEBUG
|
||||
print("ignoring localhost service")
|
||||
#endif
|
||||
return
|
||||
}
|
||||
}
|
||||
guard let endpointID=endpointID(for: service) else {return}
|
||||
#if DEBUG
|
||||
print("service name is valid, endpoint ID \(endpointID)")
|
||||
|
||||
Reference in New Issue
Block a user