summaryrefslogtreecommitdiff
path: root/src/Discovery.hs
diff options
context:
space:
mode:
authorRoman Smrž <roman.smrz@seznam.cz>2023-08-13 13:06:23 +0200
committerRoman Smrž <roman.smrz@seznam.cz>2023-08-27 12:01:16 +0200
commit0ef84b829ef2b27ce73dc84ad549d6099b28c377 (patch)
tree28d1b101c4172c455b71855fabafa5d8b22e5f1b /src/Discovery.hs
parent740c55ac1989ba5093af9350a63820a818ff0202 (diff)
Network: remove socket from peer's DatagramAddress
Diffstat (limited to 'src/Discovery.hs')
-rw-r--r--src/Discovery.hs2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/Discovery.hs b/src/Discovery.hs
index f419eab..a05fdac 100644
--- a/src/Discovery.hs
+++ b/src/Discovery.hs
@@ -107,7 +107,7 @@ instance Service DiscoveryService where
let insertHelper new old | dpPriority new > dpPriority old = new
| otherwise = old
mbaddr <- case words (T.unpack addr) of
- [ipaddr, port] | DatagramAddress _ paddr <- peerAddress peer -> do
+ [ipaddr, port] | DatagramAddress paddr <- peerAddress peer -> do
saddr <- liftIO $ head <$> getAddrInfo (Just $ defaultHints { addrSocketType = Datagram }) (Just ipaddr) (Just port)
return $ if paddr == addrAddress saddr
then Just addr