@@ -4514,8 +4514,7 @@ static int php_pgsql_add_quotes(zval *src, bool should_free)
4514
4514
{
4515
4515
smart_str str = {0 };
4516
4516
4517
- assert (Z_TYPE_P (src ) == IS_STRING );
4518
- assert (should_free == 1 || should_free == 0 );
4517
+ ZEND_ASSERT (Z_TYPE_P (src ) == IS_STRING );
4519
4518
4520
4519
smart_str_appendc (& str , 'E' );
4521
4520
smart_str_appendc (& str , '\'' );
@@ -5306,9 +5305,9 @@ PHP_PGSQL_API zend_result php_pgsql_insert(PGconn *pg_link, const zend_string *t
5306
5305
zend_result ret = FAILURE ;
5307
5306
zend_string * fld ;
5308
5307
5309
- assert (pg_link != NULL );
5310
- assert (table != NULL );
5311
- assert (Z_TYPE_P (var_array ) == IS_ARRAY );
5308
+ ZEND_ASSERT (pg_link != NULL );
5309
+ ZEND_ASSERT (table != NULL );
5310
+ ZEND_ASSERT (Z_TYPE_P (var_array ) == IS_ARRAY );
5312
5311
5313
5312
ZVAL_UNDEF (& converted );
5314
5313
if (zend_hash_num_elements (Z_ARRVAL_P (var_array )) == 0 ) {
@@ -5568,11 +5567,11 @@ PHP_PGSQL_API zend_result php_pgsql_update(PGconn *pg_link, const zend_string *t
5568
5567
smart_str querystr = {0 };
5569
5568
zend_result ret = FAILURE ;
5570
5569
5571
- assert (pg_link != NULL );
5572
- assert (table != NULL );
5573
- assert (Z_TYPE_P (var_array ) == IS_ARRAY );
5574
- assert (Z_TYPE_P (ids_array ) == IS_ARRAY );
5575
- assert (!(opt & ~(PGSQL_CONV_OPTS |PGSQL_DML_NO_CONV |PGSQL_DML_EXEC |PGSQL_DML_STRING |PGSQL_DML_ESCAPE )));
5570
+ ZEND_ASSERT (pg_link != NULL );
5571
+ ZEND_ASSERT (table != NULL );
5572
+ ZEND_ASSERT (Z_TYPE_P (var_array ) == IS_ARRAY );
5573
+ ZEND_ASSERT (Z_TYPE_P (ids_array ) == IS_ARRAY );
5574
+ ZEND_ASSERT (!(opt & ~(PGSQL_CONV_OPTS |PGSQL_DML_NO_CONV |PGSQL_DML_EXEC |PGSQL_DML_STRING |PGSQL_DML_ESCAPE )));
5576
5575
5577
5576
if (zend_hash_num_elements (Z_ARRVAL_P (var_array )) == 0
5578
5577
|| zend_hash_num_elements (Z_ARRVAL_P (ids_array )) == 0 ) {
@@ -5677,10 +5676,10 @@ PHP_PGSQL_API zend_result php_pgsql_delete(PGconn *pg_link, const zend_string *t
5677
5676
smart_str querystr = {0 };
5678
5677
zend_result ret = FAILURE ;
5679
5678
5680
- assert (pg_link != NULL );
5681
- assert (table != NULL );
5682
- assert (Z_TYPE_P (ids_array ) == IS_ARRAY );
5683
- assert (!(opt & ~(PGSQL_CONV_FORCE_NULL |PGSQL_DML_EXEC |PGSQL_DML_STRING |PGSQL_DML_ESCAPE )));
5679
+ ZEND_ASSERT (pg_link != NULL );
5680
+ ZEND_ASSERT (table != NULL );
5681
+ ZEND_ASSERT (Z_TYPE_P (ids_array ) == IS_ARRAY );
5682
+ ZEND_ASSERT (!(opt & ~(PGSQL_CONV_FORCE_NULL |PGSQL_DML_EXEC |PGSQL_DML_STRING |PGSQL_DML_ESCAPE )));
5684
5683
5685
5684
if (zend_hash_num_elements (Z_ARRVAL_P (ids_array )) == 0 ) {
5686
5685
return FAILURE ;
@@ -5773,7 +5772,8 @@ PHP_PGSQL_API void php_pgsql_result2array(PGresult *pg_result, zval *ret_array,
5773
5772
size_t num_fields ;
5774
5773
int pg_numrows , pg_row ;
5775
5774
uint32_t i ;
5776
- assert (Z_TYPE_P (ret_array ) == IS_ARRAY );
5775
+
5776
+ ZEND_ASSERT (Z_TYPE_P (ret_array ) == IS_ARRAY );
5777
5777
5778
5778
pg_numrows = PQntuples (pg_result );
5779
5779
for (pg_row = 0 ; pg_row < pg_numrows ; pg_row ++ ) {
@@ -5813,11 +5813,11 @@ PHP_PGSQL_API void php_pgsql_result2array(PGresult *pg_result, zval *ret_array,
5813
5813
zend_result ret = FAILURE ;
5814
5814
PGresult * pg_result ;
5815
5815
5816
- assert (pg_link != NULL );
5817
- assert (table != NULL );
5818
- assert (Z_TYPE_P (ids_array ) == IS_ARRAY );
5819
- assert (Z_TYPE_P (ret_array ) == IS_ARRAY );
5820
- assert (!(opt & ~(PGSQL_CONV_OPTS |PGSQL_DML_NO_CONV |PGSQL_DML_EXEC |PGSQL_DML_ASYNC |PGSQL_DML_STRING |PGSQL_DML_ESCAPE )));
5816
+ ZEND_ASSERT (pg_link != NULL );
5817
+ ZEND_ASSERT (table != NULL );
5818
+ ZEND_ASSERT (Z_TYPE_P (ids_array ) == IS_ARRAY );
5819
+ ZEND_ASSERT (Z_TYPE_P (ret_array ) == IS_ARRAY );
5820
+ ZEND_ASSERT (!(opt & ~(PGSQL_CONV_OPTS |PGSQL_DML_NO_CONV |PGSQL_DML_EXEC |PGSQL_DML_ASYNC |PGSQL_DML_STRING |PGSQL_DML_ESCAPE )));
5821
5821
5822
5822
if (zend_hash_num_elements (Z_ARRVAL_P (ids_array )) == 0 ) {
5823
5823
return FAILURE ;
0 commit comments