on master help sign in
Fix build with network >= 3.0 && < 3.1 wrt #414
commita343c4b99b20ea6f8207a220d5dccb3a88cecefa authorJulian Ospald <hasufell@posteo.de> dateMon 17 Feb 2020, 23:19 (7 years ago) parent036ca6a
1 file changed+2
src/Streamly/Internal/Network/Socket.hs+2
src/Streamly/Internal/Network/Socket.hs+2
@@ -251,6 +251,8 @@ waitWhen0 :: Int -> Socket -> IO ()
251251waitWhen0 0 s = when rtsSupportsBoundThreads $
252252#if MIN_VERSION_network(3,1,0)
253253 withFdSocket s $ \fd -> threadWaitWrite $ fromIntegral fd
254+#elif MIN_VERSION_network(3,0,0)
255+ fdSocket s >>= threadWaitWrite . fromIntegral
254256#else
255257 let fd = fdSocket s in threadWaitWrite $ fromIntegral fd
256258#endif