This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "snap-server".
The branch, master has been updated
via 0fa039c33c16ee116fb0ef686d93d9beb80bb573 (commit)
from 10c0c083e2bad38600212e5d30b70fe21f6c6d95 (commit)
Summary of changes:
src/Snap/Internal/Http/Server/GnuTLS.hs | 7 ++++---
1 files changed, 4 insertions(+), 3 deletions(-)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
commit 0fa039c33c16ee116fb0ef686d93d9beb80bb573
Author: Gregory Collins <[email protected]>
Date: Sun Feb 20 18:18:09 2011 +0100
Try again to fix gnutls compile error
diff --git a/src/Snap/Internal/Http/Server/GnuTLS.hs
b/src/Snap/Internal/Http/Server/GnuTLS.hs
index 6668d56..6ed32a4 100644
--- a/src/Snap/Internal/Http/Server/GnuTLS.hs
+++ b/src/Snap/Internal/Http/Server/GnuTLS.hs
@@ -162,7 +162,7 @@ createSession _ _ _ _ = error "Invalid socket"
------------------------------------------------------------------------------
endSession :: NetworkSession -> IO ()
-endSession (NetworkSession _ session _ _) = do
+endSession (NetworkSession _ session _) = do
throwErrorIf "TLS bye" $ gnutls_bye (castPtr session) 1 `finally` do
gnutls_deinit $ castPtr session
@@ -205,14 +205,15 @@ send tickleTimeout onBlock (NetworkSession { _session =
session}) bs =
-- could be changed to use unsafePackCStringFinalizer if the buffer is at
-- least 3/4 full and packCStringLen otherwise or something like that
recv :: IO b -> NetworkSession -> IO (Maybe ByteString)
-recv onBlock (NetworkSession _ session recvLen) = do
- fp <- BI.mallocByteString $ fromEnum recvLen
+recv onBlock (NetworkSession _ session recvLen') = do
+ fp <- BI.mallocByteString recvLen
sz <- withForeignPtr fp loop
if sz <= 0
then return Nothing
else return $ Just $ BI.fromForeignPtr fp 0 $ fromEnum sz
where
+ recvLen = fromEnum recvLen'
loop recvBuf = do
size <- gnutls_record_recv (castPtr session) recvBuf recvLen
let size' = fromIntegral size
-----------------------------------------------------------------------
hooks/post-receive
--
snap-server
_______________________________________________
Snap mailing list
[email protected]
http://mailman-mail5.webfaction.com/listinfo/snap