Removed safe library from dependencies

This commit is contained in:
VyacheslavHashov 2017-07-11 23:50:02 +03:00
parent c06fe27ac9
commit 630d90090b
2 changed files with 3 additions and 2 deletions

View File

@ -43,7 +43,6 @@ library
, socket
, socket-unix
, vector
, safe
, time
, hashable
, hashtables

View File

@ -6,7 +6,6 @@ module Database.PostgreSQL.Driver.RawConnection
import Control.Monad (void, when)
import Control.Exception (bracketOnError, try)
import Safe (headMay)
import Data.Monoid ((<>))
import Foreign (castPtr, plusPtr)
import System.Socket (socket, AddressInfo(..), getAddressInfo, socketAddress,
@ -75,6 +74,9 @@ createRawConnection settings
let dir = B.reverse . B.dropWhile (== 47) $ B.reverse dirPath
in dir <> "/" <> unixPathFilename <> portStr
headMay [] = Nothing
headMay (x:_) = Just x
constructRawConnection :: Socket f Stream p -> RawConnection
constructRawConnection s = RawConnection
{ rFlush = pure ()