diff options
-rw-r--r-- | bittorrent.cabal | 3 | ||||
-rw-r--r-- | src/Network/BitTorrent/DHT/Routing.hs | 8 |
2 files changed, 6 insertions, 5 deletions
diff --git a/bittorrent.cabal b/bittorrent.cabal index 795bac50..e517f582 100644 --- a/bittorrent.cabal +++ b/bittorrent.cabal | |||
@@ -292,4 +292,5 @@ executable client | |||
292 | , bittorrent | 292 | , bittorrent |
293 | , mtl | 293 | , mtl |
294 | , pretty-class | 294 | , pretty-class |
295 | , data-default \ No newline at end of file | 295 | , data-default |
296 | , optparse-applicative \ No newline at end of file | ||
diff --git a/src/Network/BitTorrent/DHT/Routing.hs b/src/Network/BitTorrent/DHT/Routing.hs index f62c9f56..57085cf4 100644 --- a/src/Network/BitTorrent/DHT/Routing.hs +++ b/src/Network/BitTorrent/DHT/Routing.hs | |||
@@ -199,7 +199,7 @@ defaultBucketSize :: BucketSize | |||
199 | defaultBucketSize = 8 | 199 | defaultBucketSize = 8 |
200 | 200 | ||
201 | -- | Bucket is also limited in its length — thus it's called k-bucket. | 201 | -- | Bucket is also limited in its length — thus it's called k-bucket. |
202 | -- When bucket becomes full we should split it in two lists by | 202 | -- When bucket becomes full, we should split it in two lists by |
203 | -- current span bit. Span bit is defined by depth in the routing | 203 | -- current span bit. Span bit is defined by depth in the routing |
204 | -- table tree. Size of the bucket should be choosen such that it's | 204 | -- table tree. Size of the bucket should be choosen such that it's |
205 | -- very unlikely that all nodes in bucket fail within an hour of | 205 | -- very unlikely that all nodes in bucket fail within an hour of |
@@ -315,9 +315,9 @@ instance Serialize NominalDiffTime where | |||
315 | put = putWord32be . fromIntegral . fromEnum | 315 | put = putWord32be . fromIntegral . fromEnum |
316 | get = (toEnum . fromIntegral) <$> getWord32be | 316 | get = (toEnum . fromIntegral) <$> getWord32be |
317 | 317 | ||
318 | -- | Normally, routing table should we saved between invocations of | 318 | -- | Normally, routing table should be saved between invocations of |
319 | -- the client software. Note that you don't need store /this/ 'NodeId' | 319 | -- the client software. Note that you don't need to store /this/ |
320 | -- since it is included in routing table. | 320 | -- 'NodeId' since it is already included in routing table. |
321 | instance (Eq ip, Serialize ip) => Serialize (Table ip) | 321 | instance (Eq ip, Serialize ip) => Serialize (Table ip) |
322 | 322 | ||
323 | -- | Shape of the table. | 323 | -- | Shape of the table. |