X-Git-Url: https://git.m6w6.name/?a=blobdiff_plain;f=src%2Fphp_pqcur.c;h=1ff10da22c5e9d103a2b0dc2aeacaa30a669efee;hb=90fc98eef3e8e57c2583bca4685806c3fdf183b9;hp=16057e8c5420a20d4117efa8057b4ddbb53e9bdd;hpb=c62ffa9e8cf262c412efeb84c2523d1c78897282;p=m6w6%2Fext-pq diff --git a/src/php_pqcur.c b/src/php_pqcur.c index 16057e8..1ff10da 100644 --- a/src/php_pqcur.c +++ b/src/php_pqcur.c @@ -31,7 +31,7 @@ static HashTable php_pqcur_object_prophandlers; static void cur_close(php_pqcur_object_t *obj TSRMLS_DC) { - if (obj->intern->open) { + if (obj->intern->open && obj->intern->conn->intern) { PGresult *res; smart_str cmd = {0};