Fixed bug #76548 pg_fetch_result did not fetch the next row

This commit is contained in:
Anatol Belski 2018-06-29 18:34:53 +02:00
parent bf5a802f5a
commit cb97fd3097
2 changed files with 24 additions and 0 deletions

View file

@ -2669,6 +2669,7 @@ PHP_FUNCTION(pg_fetch_result)
if (pgsql_row >= PQntuples(pgsql_result)) {
RETURN_FALSE;
}
pg_result->row++;
} else {
if (row < 0 || row >= PQntuples(pgsql_result)) {
php_error_docref(NULL, E_WARNING, "Unable to jump to row " ZEND_LONG_FMT " on PostgreSQL result index " ZEND_LONG_FMT,