diff options
Diffstat (limited to 'src/Network')
-rw-r--r-- | src/Network/Tox.hs | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/Network/Tox.hs b/src/Network/Tox.hs index d5db6979..4cc762c4 100644 --- a/src/Network/Tox.hs +++ b/src/Network/Tox.hs | |||
@@ -89,6 +89,7 @@ import Crypto.Tox | |||
89 | import Data.Word64Map (fitsInInt) | 89 | import Data.Word64Map (fitsInInt) |
90 | import qualified Data.Word64Map (empty) | 90 | import qualified Data.Word64Map (empty) |
91 | import Network.Tox.Crypto.Transport (NetCrypto) | 91 | import Network.Tox.Crypto.Transport (NetCrypto) |
92 | import Network.Tox.Crypto.Handlers (newSessionsState, cryptoNetHandler) | ||
92 | import qualified Network.Tox.DHT.Handlers as DHT | 93 | import qualified Network.Tox.DHT.Handlers as DHT |
93 | import qualified Network.Tox.DHT.Transport as DHT | 94 | import qualified Network.Tox.DHT.Transport as DHT |
94 | import Network.Tox.NodeId | 95 | import Network.Tox.NodeId |
@@ -308,11 +309,12 @@ newTox keydb addr = do | |||
308 | (const id) | 309 | (const id) |
309 | 310 | ||
310 | roster <- newRoster | 311 | roster <- newRoster |
312 | sessionsState <- newSessionsState crypto | ||
311 | return Tox | 313 | return Tox |
312 | { toxDHT = dhtclient | 314 | { toxDHT = dhtclient |
313 | , toxOnion = onionclient | 315 | , toxOnion = onionclient |
314 | , toxToRoute = onInbound (updateRoster roster) dtacrypt | 316 | , toxToRoute = onInbound (updateRoster roster) dtacrypt |
315 | , toxCrypto = cryptonet | 317 | , toxCrypto = addHandler (error "printErrors stderr") (cryptoNetHandler sessionsState) cryptonet |
316 | , toxCryptoKeys = crypto | 318 | , toxCryptoKeys = crypto |
317 | , toxRouting = routing | 319 | , toxRouting = routing |
318 | , toxTokens = toks | 320 | , toxTokens = toks |