X-Git-Url: https://git.m6w6.name/?p=m6w6%2Fext-pq;a=blobdiff_plain;f=src%2Fphp_pqstm.c;h=ba1203721bcbeaf547cb16b3d128bec6012965bb;hp=f3136d9f62cd8b577e7badf4636b734b366eb45f;hb=c62ffa9e8cf262c412efeb84c2523d1c78897282;hpb=18db85e4b2f6d221cb6f09838dc7ac7f873e9ba6 diff --git a/src/php_pqstm.c b/src/php_pqstm.c index f3136d9..ba12037 100644 --- a/src/php_pqstm.c +++ b/src/php_pqstm.c @@ -250,8 +250,10 @@ static PHP_METHOD(pqstm, execAsync) { if (!rc) { throw_exce(EX_IO TSRMLS_CC, "Failed to execute statement (%s)", PHP_PQerrorMessage(obj->intern->conn->intern->conn)); +#if HAVE_PQSETSINGLEROWMODE } else if (obj->intern->conn->intern->unbuffered && !PQsetSingleRowMode(obj->intern->conn->intern->conn)) { throw_exce(EX_RUNTIME TSRMLS_CC, "Failed to enable unbuffered mode (%s)", PHP_PQerrorMessage(obj->intern->conn->intern->conn)); +#endif } else { php_pq_callback_recurse(&obj->intern->conn->intern->onevent, &resolver TSRMLS_CC); obj->intern->conn->intern->poller = PQconsumeInput;