summaryrefslogtreecommitdiff
path: root/src/Network/Tox/DHT
diff options
context:
space:
mode:
Diffstat (limited to 'src/Network/Tox/DHT')
-rw-r--r--src/Network/Tox/DHT/Transport.hs8
1 files changed, 3 insertions, 5 deletions
diff --git a/src/Network/Tox/DHT/Transport.hs b/src/Network/Tox/DHT/Transport.hs
index e784ec90..b9b63165 100644
--- a/src/Network/Tox/DHT/Transport.hs
+++ b/src/Network/Tox/DHT/Transport.hs
@@ -382,13 +382,11 @@ instance Sized CookieData where
382 size = ConstSize 72 382 size = ConstSize 72
383 383
384instance Serialize CookieData where 384instance Serialize CookieData where
385 get = CookieData <$> get 385 get = CookieData <$> get <*> getPublicKey <*> getPublicKey
386 <*> (id2key <$> get)
387 <*> (id2key <$> get)
388 put (CookieData tm userkey dhtkey) = do 386 put (CookieData tm userkey dhtkey) = do
389 put tm 387 put tm
390 put (key2id userkey) 388 putPublicKey userkey
391 put (key2id dhtkey) 389 putPublicKey userkey
392 390
393instance Sized CookieRequest where 391instance Sized CookieRequest where
394 size = ConstSize 64 -- 32 byte key + 32 byte padding 392 size = ConstSize 64 -- 32 byte key + 32 byte padding