summaryrefslogtreecommitdiff
path: root/src/Network/DHT/Routing.hs
diff options
context:
space:
mode:
Diffstat (limited to 'src/Network/DHT/Routing.hs')
-rw-r--r--src/Network/DHT/Routing.hs3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/Network/DHT/Routing.hs b/src/Network/DHT/Routing.hs
index 0eb1078b..273cf9dc 100644
--- a/src/Network/DHT/Routing.hs
+++ b/src/Network/DHT/Routing.hs
@@ -550,6 +550,9 @@ tableBits testbit (BucketList self _ bkts) =
550 zipWith const (map (testbit self) [0..]) 550 zipWith const (map (testbit self) [0..])
551 bkts 551 bkts
552 552
553selfNode :: BucketList ni -> ni
554selfNode (BucketList self _ _) = self
555
553chunksOf :: Int -> [e] -> [[e]] 556chunksOf :: Int -> [e] -> [[e]]
554chunksOf i ls = map (take i) (build (splitter ls)) where 557chunksOf i ls = map (take i) (build (splitter ls)) where
555 splitter :: [e] -> ([e] -> a -> a) -> a -> a 558 splitter :: [e] -> ([e] -> a -> a) -> a -> a