summaryrefslogtreecommitdiff
path: root/src/Network/BitTorrent
diff options
context:
space:
mode:
authorjoe <joe@jerkface.net>2017-01-17 22:45:34 -0500
committerjoe <joe@jerkface.net>2017-01-17 22:45:34 -0500
commit887c57d7880b36bb6206cd4af3a1dcc8b3d3b999 (patch)
tree8acd7738325a0923470246039fd89cfa8396c402 /src/Network/BitTorrent
parent9d3b8a2589aef84472746dd57306b9d07920e073 (diff)
Enable responding to get_peers.
Diffstat (limited to 'src/Network/BitTorrent')
-rw-r--r--src/Network/BitTorrent/DHT/Session.hs7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/Network/BitTorrent/DHT/Session.hs b/src/Network/BitTorrent/DHT/Session.hs
index d9a50a15..c8545bfd 100644
--- a/src/Network/BitTorrent/DHT/Session.hs
+++ b/src/Network/BitTorrent/DHT/Session.hs
@@ -409,10 +409,11 @@ getClosest node = do
409-- Peer storage 409-- Peer storage
410-----------------------------------------------------------------------} 410-----------------------------------------------------------------------}
411 411
412-- TODO limit dht peer store in size (probably by removing oldest peers)
413
414refreshContacts :: DHT ip () 412refreshContacts :: DHT ip ()
415refreshContacts = undefined 413refreshContacts =
414 -- TODO limit dht peer store in size (probably by removing oldest peers)
415 return ()
416
416 417
417-- | Insert peer to peer store. Used to handle announce requests. 418-- | Insert peer to peer store. Used to handle announce requests.
418insertPeer :: Eq ip => InfoHash -> PeerAddr ip -> DHT ip () 419insertPeer :: Eq ip => InfoHash -> PeerAddr ip -> DHT ip ()