]> git.ipfire.org Git - thirdparty/psycopg.git/commitdiff
Fix definitions for pipeline replacements macros
authorDaniele Varrazzo <daniele.varrazzo@gmail.com>
Fri, 14 Jan 2022 00:48:12 +0000 (01:48 +0100)
committerDaniele Varrazzo <daniele.varrazzo@gmail.com>
Fri, 14 Jan 2022 01:50:24 +0000 (02:50 +0100)
The previous definition caused a warning for implicit conversion from
void* to int.

psycopg_c/psycopg_c/pq/libpq.pxd

index e59552270ec55e668e5a724a7a9f58a9821ed2e7..b66ca8cd2f9658966de9f719463f23256c85ae8c 100644 (file)
@@ -311,10 +311,10 @@ typedef enum {
     PQ_PIPELINE_ON,
     PQ_PIPELINE_ABORTED
 } PGpipelineStatus;
-#define PQpipelineStatus(conn) NULL
-#define PQenterPipelineMode(conn) NULL
-#define PQexitPipelineMode(conn) NULL
-#define PQpipelineSync(conn) NULL
-#define PQsendFlushRequest(conn) NULL
+#define PQpipelineStatus(conn) PQ_PIPELINE_OFF
+#define PQenterPipelineMode(conn) 0
+#define PQexitPipelineMode(conn) 1
+#define PQpipelineSync(conn) 0
+#define PQsendFlushRequest(conn) 0
 #endif
 """