diff options
Diffstat (limited to 'src/Network/BitTorrent')
-rw-r--r-- | src/Network/BitTorrent/DHT/Query.hs | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/Network/BitTorrent/DHT/Query.hs b/src/Network/BitTorrent/DHT/Query.hs index e0338572..8215c95d 100644 --- a/src/Network/BitTorrent/DHT/Query.hs +++ b/src/Network/BitTorrent/DHT/Query.hs | |||
@@ -75,6 +75,7 @@ import Data.Time.Clock.POSIX | |||
75 | 75 | ||
76 | import Network.KRPC hiding (Options, def) | 76 | import Network.KRPC hiding (Options, def) |
77 | import Network.KRPC.Message (ReflectedIP(..)) | 77 | import Network.KRPC.Message (ReflectedIP(..)) |
78 | import Network.KRPC.Manager (QueryFailure(..)) | ||
78 | import Data.Torrent | 79 | import Data.Torrent |
79 | import Network.BitTorrent.Address | 80 | import Network.BitTorrent.Address |
80 | import Network.BitTorrent.DHT.Message | 81 | import Network.BitTorrent.DHT.Message |
@@ -206,7 +207,7 @@ probeNode :: Address ip => NodeAddr ip -> DHT ip (Bool, Maybe ReflectedIP) | |||
206 | probeNode addr = do | 207 | probeNode addr = do |
207 | $(logDebugS) "routing.questionable_node" (T.pack (render (pPrint addr))) | 208 | $(logDebugS) "routing.questionable_node" (T.pack (render (pPrint addr))) |
208 | result <- try $ pingQ addr | 209 | result <- try $ pingQ addr |
209 | let _ = fmap (const ()) result :: Either SomeException () | 210 | let _ = fmap (const ()) result :: Either QueryFailure () |
210 | return $ either (const (False,Nothing)) (\(_,mip)->(True,mip)) result | 211 | return $ either (const (False,Nothing)) (\(_,mip)->(True,mip)) result |
211 | 212 | ||
212 | 213 | ||