com php-src: Merge branch 'PHP-7.0' into PHP-7.1: sapi/phpdbg/p hpdbg_help.c sapi/phpdbg/phpdbg_list.c

From: Date: Wed, 05 Oct 2016 10:20:06 +0000
Subject: com php-src: Merge branch 'PHP-7.0' into PHP-7.1: sapi/phpdbg/p hpdbg_help.c sapi/phpdbg/phpdbg_list.c
Groups: php.cvs 
Request: Send a blank email to php-cvs+get-94831@lists.php.net to get a copy of this message
Commit: abfd811ea40cda928a70664b33e5c25f005b3e99 Author: Bob Weinand <bobwei9@hotmail.com> Wed, 5 Oct 2016 12:20:06 +0200 Parents: cc2a0dd01899bcd6cfda557faecd4758544ad5b3 4790da5475c80469eeaac777f3f04815648e3d96 Branches: PHP-7.1 Link: http://git.php.net/?p=php-src.git;a=commitdiff;h=abfd811ea40cda928a70664b33e5c25f005b3e99 Log: Merge branch 'PHP-7.0' into PHP-7.1 Changed paths: MM sapi/phpdbg/phpdbg_help.c MM sapi/phpdbg/phpdbg_list.c Diff: diff --cc sapi/phpdbg/phpdbg_list.c index a1403db,6895bea..dd0187c --- a/sapi/phpdbg/phpdbg_list.c +++ b/sapi/phpdbg/phpdbg_list.c @@@ -317,17 -316,6 +317,17 @@@ zend_op_array *phpdbg_init_compile_file dataptr = zend_hash_str_find_ptr(&PHPDBG_G(file_sources), filename, strlen(filename)); ZEND_ASSERT(dataptr != NULL); + if (op_array->vars) { + int i; - /* un-intern these strings to prevent zend_restore_strings from invalidating our string pointers too early */ ++ /* un-intern these strings to prevent zend_interned_strings_restore from invalidating our string pointers too early (in phpdbg allocated memory only gets freed after module shutdown) */ + for (i = 0; i < op_array->last_var; i++) { + zend_string **s = op_array->vars + i; + if (ZSTR_IS_INTERNED(*s)) { + *s = zend_string_init(ZSTR_VAL(*s), ZSTR_LEN(*s), 0); + } + } + } + dataptr->op_array = *op_array; if (dataptr->op_array.refcount) { ++*dataptr->op_array.refcount;

« previous php.cvs (#94831) next »