diff options
| author | Dmitry Stogov <dmitry@zend.com> | 2018-07-04 19:22:24 +0300 | 
|---|---|---|
| committer | Dmitry Stogov <dmitry@zend.com> | 2018-07-04 19:22:24 +0300 | 
| commit | 4a475a4976db92e71949786cdf5990c61514261e (patch) | |
| tree | 6934c9e00200e6388256656b8fa71c97a1a3a158 /ext/mbstring/php_mbregex.c | |
| parent | d798fd491be77943fb751ad97d85475bf324192c (diff) | |
| download | php-git-4a475a4976db92e71949786cdf5990c61514261e.tar.gz | |
Replace legacy zval_dtor() by zval_ptr_dtor_nogc() or even more specialized destructors.
zval_dtor() doesn't make a lot of sense in PHP-7.* and it's used incorrectly in some places.
Its occurances should be replaced by zval_ptr_dtor() or zval_ptr_dtor_nogc(), or even more specialized destructors.
Diffstat (limited to 'ext/mbstring/php_mbregex.c')
| -rw-r--r-- | ext/mbstring/php_mbregex.c | 4 | 
1 files changed, 2 insertions, 2 deletions
diff --git a/ext/mbstring/php_mbregex.c b/ext/mbstring/php_mbregex.c index 4d3e44f1ec..608cdc9d8f 100644 --- a/ext/mbstring/php_mbregex.c +++ b/ext/mbstring/php_mbregex.c @@ -986,7 +986,7 @@ static void _php_mb_regex_ereg_replace_exec(INTERNAL_FUNCTION_PARAMETERS, OnigOp  				smart_str_appendl(&out_buf, Z_STRVAL(v), Z_STRLEN(v));  				/* Clean up */  				smart_str_free(&eval_buf); -				zval_dtor(&v); +				zval_ptr_dtor_str(&v);  			} else if (is_callable) {  				zval args[1];  				zval subpats, retval; @@ -1146,7 +1146,7 @@ PHP_FUNCTION(mb_split)  		OnigUChar err_str[ONIG_MAX_ERROR_MESSAGE_LEN];  		onig_error_code_to_str(err_str, err);  		php_error_docref(NULL, E_WARNING, "mbregex search failure in mbsplit(): %s", err_str); -		zval_dtor(return_value); +		zend_array_destroy(Z_ARR_P(return_value));  		RETURN_FALSE;  	}  | 
