From 49d18d9f256f681d51341ccf77bebc4fece2b7b1 Mon Sep 17 00:00:00 2001 From: foobar Date: Sun, 27 May 2001 23:26:58 +0000 Subject: [PATCH] Fix by Sterling Hughes. Fixes bugs: #10939, #10756, #10324 --- ext/pgsql/pgsql.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/ext/pgsql/pgsql.c b/ext/pgsql/pgsql.c index fac6baef9f..3e193254c0 100644 --- a/ext/pgsql/pgsql.c +++ b/ext/pgsql/pgsql.c @@ -172,9 +172,13 @@ _notice_handler(void *arg, const char *message) static int _rollback_transactions(zend_rsrc_list_entry *rsrc) { - PGconn *link = (PGconn *)rsrc->ptr; + PGconn *link; PGLS_FETCH(); + if (rsrc->type != le_plink) return 0; + + link = (PGconn *)rsrc->ptr; + PGG(ignore_notices) = 1; PQexec(link,"BEGIN;ROLLBACK;"); PGG(ignore_notices) = 0; -- 2.50.1