com php-src: fix crash in phpdbg shutdown process when opcache is loaded: sapi/phpdbg/phpdbg.c

[email protected] (Joe Watkins)
Newsgroups php.cvs
Message-ID <[email protected]>
Commit:    008fb28eafa3740b1e3696b1a5cf7566d493b97d
Author:    Joe Watkins <[email protected]>         Mon, 27 Feb 2017 17:54:48 +0000
Parents:   bbfa1b64192fe3ccd2898e6e1f997387b4f210d1
Branches:  PHP-7.0 PHP-7.1 master

Link:       http://git.php.net/?p=php-src.git;a=commitdiff;h=008fb28eafa3740b1e3696b1a5cf7566d493b97d

Log:
fix crash in phpdbg shutdown process when opcache is loaded

Changed paths:
  M  sapi/phpdbg/phpdbg.c


Diff:
diff --git a/sapi/phpdbg/phpdbg.c b/sapi/phpdbg/phpdbg.c
index c407885..37314e6 100644
--- a/sapi/phpdbg/phpdbg.c
+++ b/sapi/phpdbg/phpdbg.c
@@ -228,7 +228,6 @@ static PHP_RSHUTDOWN_FUNCTION(phpdbg) /* {{{ */
 	zend_hash_destroy(&PHPDBG_G(bp)[PHPDBG_BREAK_METHOD]);
 	zend_hash_destroy(&PHPDBG_G(bp)[PHPDBG_BREAK_COND]);
 	zend_hash_destroy(&PHPDBG_G(bp)[PHPDBG_BREAK_MAP]);
-	zend_hash_destroy(&PHPDBG_G(file_sources));
 	zend_hash_destroy(&PHPDBG_G(seek));
 	zend_hash_destroy(&PHPDBG_G(registered));
 	zend_hash_destroy(&PHPDBG_G(watchpoints));
@@ -2137,6 +2136,8 @@ phpdbg_out:
 			wrapper->wops->stream_opener = PHPDBG_G(orig_url_wrap_php);
 		}
 
+		zend_hash_destroy(&PHPDBG_G(file_sources));
+
 		zend_try {
 			php_module_shutdown();
 		} zend_end_try();
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.