File tree Expand file tree Collapse file tree 1 file changed +4
-10
lines changed Expand file tree Collapse file tree 1 file changed +4
-10
lines changed Original file line number Diff line number Diff line change @@ -2528,13 +2528,10 @@ static bool ZEND_FASTCALL increment_string(zval *str) /* {{{ */
2528
2528
2529
2529
if (UNEXPECTED (!zend_string_only_has_ascii_alphanumeric (Z_STR_P (str )))) {
2530
2530
zend_string * zstr = Z_STR_P (str );
2531
- GC_TRY_ADDREF (zstr );
2531
+ zend_string_addref (zstr );
2532
2532
zend_error (E_DEPRECATED , "Increment on non-alphanumeric string is deprecated" );
2533
2533
if (EG (exception )) {
2534
- GC_TRY_DELREF (zstr );
2535
- if (!GC_REFCOUNT (zstr )) {
2536
- efree (zstr );
2537
- }
2534
+ zend_string_release (zstr );
2538
2535
return false;
2539
2536
}
2540
2537
zval_ptr_dtor (str );
@@ -2740,13 +2737,10 @@ ZEND_API zend_result ZEND_FASTCALL decrement_function(zval *op1) /* {{{ */
2740
2737
default : {
2741
2738
/* Error handler can unset the variable */
2742
2739
zend_string * zstr = Z_STR_P (op1 );
2743
- GC_TRY_ADDREF (zstr );
2740
+ zend_string_addref (zstr );
2744
2741
zend_error (E_DEPRECATED , "Decrement on non-numeric string has no effect and is deprecated" );
2745
2742
if (EG (exception )) {
2746
- GC_TRY_DELREF (zstr );
2747
- if (!GC_REFCOUNT (zstr )) {
2748
- efree (zstr );
2749
- }
2743
+ zend_string_release (zstr );
2750
2744
return FAILURE ;
2751
2745
}
2752
2746
zval_ptr_dtor (op1 );
You can’t perform that action at this time.
0 commit comments