From bb1d095085f14b31a0ee285529dbe2dfa964b149 Mon Sep 17 00:00:00 2001 From: James Crayne Date: Wed, 20 Jun 2018 06:29:36 +0000 Subject: netcrypto bug fixes --- examples/dhtd.hs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'examples') diff --git a/examples/dhtd.hs b/examples/dhtd.hs index 36a9fa68..f6c57130 100644 --- a/examples/dhtd.hs +++ b/examples/dhtd.hs @@ -1722,7 +1722,8 @@ main = runResourceT $ liftBaseWith $ \resT -> do let sockAddr = Tox.ncSockAddr netcrypto pubKey = Tox.ncTheirPublicKey netcrypto tmchan <- atomically newTMChan - let Just pingMachine = Tox.ncPingMachine netcrypto + mbPingMaching <- atomically $ readTVar (Tox.ncPingMachine netcrypto) + let Just pingMachine = mbPingMaching pingflag = readTVar (pingFlag pingMachine) receiveCrypto = atomically $ readTMChan tmchan onEOF = return () -- TODO: Update toxContactInfo, not connected. -- cgit v1.2.3