postgresql-libpq 0.9.2.0 → 0.9.3.0
raw patch · 2 files changed
+12/−6 lines, 2 filesPVP ok
version bump matches the API change (PVP)
API changes (from Hackage documentation)
+ Database.PostgreSQL.LibPQ: CopyBoth :: ExecStatus
Files
postgresql-libpq.cabal view
@@ -1,5 +1,5 @@ Name: postgresql-libpq-Version: 0.9.2.0+Version: 0.9.3.0 Synopsis: low-level binding to libpq Description: This is a binding to libpq: the C application@@ -54,4 +54,4 @@ source-repository this type: git location: http://github.com/lpsmith/postgresql-libpq- tag: v0.9.2.0+ tag: v0.9.3.0
src/Database/PostgreSQL/LibPQ.hsc view
@@ -961,6 +961,7 @@ -- transfer started. | CopyIn -- ^ Copy In (to server) data transfer -- started.+ | CopyBoth -- ^ Copy In/Out data transfer started. | BadResponse -- ^ The server's response was not understood. | NonfatalError -- ^ A nonfatal error (a notice or -- warning) occurred.@@ -977,6 +978,7 @@ toEnum (#const PGRES_TUPLES_OK) = TuplesOk toEnum (#const PGRES_COPY_OUT) = CopyOut toEnum (#const PGRES_COPY_IN) = CopyIn+ toEnum (#const PGRES_COPY_BOTH) = CopyBoth toEnum (#const PGRES_BAD_RESPONSE) = BadResponse toEnum (#const PGRES_NONFATAL_ERROR) = NonfatalError toEnum (#const PGRES_FATAL_ERROR) = FatalError@@ -988,6 +990,7 @@ fromEnum TuplesOk = (#const PGRES_TUPLES_OK) fromEnum CopyOut = (#const PGRES_COPY_OUT) fromEnum CopyIn = (#const PGRES_COPY_IN)+ fromEnum CopyBoth = (#const PGRES_COPY_BOTH) fromEnum BadResponse = (#const PGRES_BAD_RESPONSE) fromEnum NonfatalError = (#const PGRES_NONFATAL_ERROR) fromEnum FatalError = (#const PGRES_FATAL_ERROR)@@ -2113,10 +2116,13 @@ -- later call 'disableNoticeReporting' after calling this function. enableNoticeReporting :: Connection -> IO () enableNoticeReporting conn@(Conn _ nbRef) = do- nb' <- c_malloc_noticebuffer- _ <- withConn conn $ \c -> c_PQsetNoticeReceiver c p_store_notices nb'- nb <- swapMVar nbRef nb'- c_free_noticebuffer nb+ if isNullConnection conn+ then return ()+ else do+ nb' <- c_malloc_noticebuffer+ _ <- withConn conn $ \c -> c_PQsetNoticeReceiver c p_store_notices nb'+ nb <- swapMVar nbRef nb'+ c_free_noticebuffer nb -- | This function retrieves any notices received from the backend. -- Because multiple notices can be received at a time, you will