From 8ff2f2f84b2c0ea33b38f7e98aaa710ce4f3fc91 Mon Sep 17 00:00:00 2001 From: Nikita Popov Date: Mon, 21 Sep 2020 17:20:28 +0200 Subject: Return empty array for no rows in pg_fetch_all() This makes it line up with pg_fetch_all_columns(), as well as similar functions in other exts, such as mysqli_fetch_all(). --- ext/pgsql/php_pgsql.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'ext/pgsql/php_pgsql.h') diff --git a/ext/pgsql/php_pgsql.h b/ext/pgsql/php_pgsql.h index fe52d9ce96..3da04282d9 100644 --- a/ext/pgsql/php_pgsql.h +++ b/ext/pgsql/php_pgsql.h @@ -182,7 +182,7 @@ PHP_PGSQL_API int php_pgsql_insert(PGconn *pg_link, const char *table, zval *val PHP_PGSQL_API int php_pgsql_update(PGconn *pg_link, const char *table, zval *values, zval *ids, zend_ulong opt , zend_string **sql); PHP_PGSQL_API int php_pgsql_delete(PGconn *pg_link, const char *table, zval *ids, zend_ulong opt, zend_string **sql); PHP_PGSQL_API int php_pgsql_select(PGconn *pg_link, const char *table, zval *ids, zval *ret_array, zend_ulong opt, long fetch_option, zend_string **sql ); -PHP_PGSQL_API int php_pgsql_result2array(PGresult *pg_result, zval *ret_array, long fetch_option); +PHP_PGSQL_API void php_pgsql_result2array(PGresult *pg_result, zval *ret_array, long fetch_option); /* internal functions */ static void php_pgsql_do_connect(INTERNAL_FUNCTION_PARAMETERS,int persistent); -- cgit v1.2.1