diff options
Diffstat (limited to 'src/Network/BitTorrent/MainlineDHT.hs')
-rw-r--r-- | src/Network/BitTorrent/MainlineDHT.hs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/Network/BitTorrent/MainlineDHT.hs b/src/Network/BitTorrent/MainlineDHT.hs index a7359bda..c0413322 100644 --- a/src/Network/BitTorrent/MainlineDHT.hs +++ b/src/Network/BitTorrent/MainlineDHT.hs | |||
@@ -444,7 +444,7 @@ encodePacket :: Message BValue -> NodeInfo -> (ByteString, SockAddr) | |||
444 | encodePacket msg ni = ( toStrict $ BE.encode msg | 444 | encodePacket msg ni = ( toStrict $ BE.encode msg |
445 | , nodeAddr ni ) | 445 | , nodeAddr ni ) |
446 | 446 | ||
447 | classify :: Message BValue -> MessageClass String Method TransactionId | 447 | classify :: Message BValue -> MessageClass String Method TransactionId NodeInfo (Message BValue) |
448 | classify (Q { msgID = tid, qryMethod = meth }) = IsQuery meth tid | 448 | classify (Q { msgID = tid, qryMethod = meth }) = IsQuery meth tid |
449 | classify (R { msgID = tid }) = IsResponse tid | 449 | classify (R { msgID = tid }) = IsResponse tid |
450 | 450 | ||
@@ -566,7 +566,7 @@ newClient swarms addr = do | |||
566 | outgoingClient = client { clientNet = net { awaitMessage = ($ Nothing) } } | 566 | outgoingClient = client { clientNet = net { awaitMessage = ($ Nothing) } } |
567 | 567 | ||
568 | dispatch = DispatchMethods | 568 | dispatch = DispatchMethods |
569 | { classifyInbound = classify -- :: x -> MessageClass err meth tid | 569 | { classifyInbound = classify -- :: x -> MessageClass err meth tid addr x |
570 | , lookupHandler = handlers -- :: meth -> Maybe (MethodHandler err tid addr x) | 570 | , lookupHandler = handlers -- :: meth -> Maybe (MethodHandler err tid addr x) |
571 | , tableMethods = mapT -- :: TransactionMethods tbl tid x | 571 | , tableMethods = mapT -- :: TransactionMethods tbl tid x |
572 | } | 572 | } |