From d96234b9954fb2e41521eb437edf2fee7317f7d6 Mon Sep 17 00:00:00 2001 From: Joe Crayne Date: Wed, 12 Dec 2018 02:01:39 -0500 Subject: TCP Prober. --- src/Network/Tox.hs | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'src/Network/Tox.hs') diff --git a/src/Network/Tox.hs b/src/Network/Tox.hs index ea9bbe56..d42f447d 100644 --- a/src/Network/Tox.hs +++ b/src/Network/Tox.hs @@ -65,6 +65,7 @@ import Network.Tox.ContactInfo import Text.XXD import DPut import DebugTag +import TCPProber import Network.Tox.Avahi import Network.Tox.Session import Network.Tox.Relay @@ -375,6 +376,10 @@ forkTox tox with_avahi = do quitNC <- forkListener "toxCrypto" (toxCrypto tox) quitTCP <- forkListener "relay-client" (clientNet $ tcpClient $ tcpKademliaClient $ toxOnionRoutes tox) tcpKademlia <- forkPollForRefresh (tcpBucketRefresher $ toxOnionRoutes tox) + tcpprobe <- forkIO $ runProbeQueue (tcpProber $ toxOnionRoutes tox) + (tcpClient $ tcpKademliaClient $ toxOnionRoutes tox) + 12 + labelThread tcpprobe "tcp-probe" quitAvahi <- if with_avahi then do forkPollForRefresh (DHT.refresher4 $ toxRouting tox) forkPollForRefresh (DHT.refresher6 $ toxRouting tox) @@ -392,6 +397,7 @@ forkTox tox with_avahi = do quitOnion quitTCP killThread tcpKademlia + killThread tcpprobe quitToRoute quitHs , bootstrap (DHT.refresher4 $ toxRouting tox) -- cgit v1.2.3