diff options
Diffstat (limited to 'examples/dhtd.hs')
-rw-r--r-- | examples/dhtd.hs | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/examples/dhtd.hs b/examples/dhtd.hs index cdaa73ed..db8664e8 100644 --- a/examples/dhtd.hs +++ b/examples/dhtd.hs | |||
@@ -1576,9 +1576,11 @@ announceToxJabberPeer :: PublicKey -- ^ This node's long-term user key. | |||
1576 | -> IO (Maybe (Tox.NetCryptoSession -> Tox.NetCryptoSession)) | 1576 | -> IO (Maybe (Tox.NetCryptoSession -> Tox.NetCryptoSession)) |
1577 | announceToxJabberPeer me them echan laddr saddr pingflag tsrc tsnk | 1577 | announceToxJabberPeer me them echan laddr saddr pingflag tsrc tsnk |
1578 | = do | 1578 | = do |
1579 | atomically $ writeTChan echan | 1579 | atomically $ do |
1580 | ( (saddr, ConnectionData (Left (Local laddr)) XMPPServer.Tox (xmppHostname me) ) | 1580 | v <- newTVar Nothing |
1581 | , Tcp.Connection pingflag xsrc xsnk ) | 1581 | writeTChan echan |
1582 | ( (saddr, ConnectionData (Left (Local laddr)) XMPPServer.Tox (xmppHostname me) v) | ||
1583 | , Tcp.Connection pingflag xsrc xsnk ) | ||
1582 | return Nothing | 1584 | return Nothing |
1583 | where | 1585 | where |
1584 | xsrc = tsrc =$= toxToXmpp laddr me (xmppHostname them) | 1586 | xsrc = tsrc =$= toxToXmpp laddr me (xmppHostname them) |