From faeda1974408f7bdac36aa2f081f456120809ecb Mon Sep 17 00:00:00 2001 From: Jon Kristensen Date: Mon, 27 Jul 2015 01:38:05 +0200 Subject: [PATCH] Fix TLS build problem --- pontarius-xmpp.cabal | 4 ++-- source/Network/Xmpp/Tls.hs | 9 ++++----- 2 files changed, 6 insertions(+), 7 deletions(-) diff --git a/pontarius-xmpp.cabal b/pontarius-xmpp.cabal index 7de7d52..d302b5b 100644 --- a/pontarius-xmpp.cabal +++ b/pontarius-xmpp.cabal @@ -1,5 +1,5 @@ Name: pontarius-xmpp -Version: 0.4.2.1 +Version: 0.4.2.2 Cabal-Version: >= 1.9.2 Build-Type: Custom License: BSD3 @@ -210,4 +210,4 @@ Source-Repository head Source-Repository this Type: git Location: git://github.com/pontarius/pontarius-xmpp.git - Tag: 0.4.0.2 + Tag: 0.4.2.2 diff --git a/source/Network/Xmpp/Tls.hs b/source/Network/Xmpp/Tls.hs index d21f5db..6e4bed9 100644 --- a/source/Network/Xmpp/Tls.hs +++ b/source/Network/Xmpp/Tls.hs @@ -110,9 +110,8 @@ tls con = fmap join -- We can have Left values both from exceptions and the modify (\s -> s{streamConnectionState = Secured}) return () -client :: (MonadIO m, CPRG rng) => ClientParams -> rng -> Backend -> m Context -client params gen backend = do - contextNew backend params gen +client :: MonadIO m => ClientParams -> Backend -> m Context +client params backend = contextNew backend params tlsinit :: (MonadIO m, MonadIO m1) => ClientParams @@ -125,12 +124,12 @@ tlsinit :: (MonadIO m, MonadIO m1) => ) tlsinit params backend = do liftIO $ debugM "Pontarius.Xmpp.Tls" "TLS with debug mode enabled." - gen <- liftIO (cprgCreate <$> createEntropyPool :: IO SystemRNG) + -- gen <- liftIO (cprgCreate <$> createEntropyPool :: IO SystemRNG) sysCStore <- liftIO getSystemCertificateStore let params' = params{clientShared = (clientShared params){ sharedCAStore = sysCStore <> sharedCAStore (clientShared params)}} - con <- client params' gen backend + con <- client params' backend handshake con let src = forever $ do dt <- liftIO $ recvData con