diff options
author | Stanislav Malyshev <stas@php.net> | 2014-05-08 01:01:15 -0700 |
---|---|---|
committer | Stanislav Malyshev <stas@php.net> | 2014-05-08 01:01:15 -0700 |
commit | 0c709cc2dc2932bd831d40a2f8db80308c0b913e (patch) | |
tree | 9ad649ee6ac016285d85c30af4f657659237598d /ext/bz2/bz2.c | |
parent | 27f5957e9f5e8526033d946aaa02ad3bb07023b6 (diff) | |
parent | a444900c8df384f51bdfe5a8fe867a2a40978fe7 (diff) | |
download | php-git-0c709cc2dc2932bd831d40a2f8db80308c0b913e.tar.gz |
Merge branch 'PHP-5.5' into PHP-5.6
* PHP-5.5:
Fix memory leak in TSRM
Diffstat (limited to 'ext/bz2/bz2.c')
-rw-r--r-- | ext/bz2/bz2.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/ext/bz2/bz2.c b/ext/bz2/bz2.c index cc845584f0..93bcaccec8 100644 --- a/ext/bz2/bz2.c +++ b/ext/bz2/bz2.c @@ -230,6 +230,9 @@ PHP_BZ2_API php_stream *_php_stream_bz2open(php_stream_wrapper *wrapper, #endif if (php_check_open_basedir(path_copy TSRMLS_CC)) { +#ifdef VIRTUAL_DIR + efree(path_copy); +#endif return NULL; } @@ -239,6 +242,9 @@ PHP_BZ2_API php_stream *_php_stream_bz2open(php_stream_wrapper *wrapper, if (opened_path && bz_file) { *opened_path = estrdup(path_copy); } +#ifdef VIRTUAL_DIR + efree(path_copy); +#endif path_copy = NULL; if (bz_file == NULL) { |