Skip to content

Commit 442ae96

Browse files
committed
Merge branch 'PHP-8.3'
* PHP-8.3: Fix GH-15028: Memory leak in ext/phar/stream.c Fix GH-15023: Memory leak in Zend/zend_ini.c Fix GH-15020: Memory leak in Zend/Optimizer/escape_analysis.c
2 parents d75abdc + f21947a commit 442ae96

File tree

3 files changed

+3
-0
lines changed

3 files changed

+3
-0
lines changed

Zend/Optimizer/escape_analysis.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -414,6 +414,7 @@ zend_result zend_ssa_escape_analysis(const zend_script *script, zend_op_array *o
414414
}
415415

416416
if (zend_build_equi_escape_sets(ees, op_array, ssa) == FAILURE) {
417+
free_alloca(ees, use_heap);
417418
return FAILURE;
418419
}
419420

Zend/zend_ini.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -243,6 +243,7 @@ ZEND_API zend_result zend_register_ini_entries_ex(const zend_ini_entry_def *ini_
243243
if (p->name) {
244244
zend_string_release_ex(p->name, 1);
245245
}
246+
pefree(p, true);
246247
zend_unregister_ini_entries_ex(module_number, module_type);
247248
return FAILURE;
248249
}

ext/phar/stream.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -782,6 +782,7 @@ static int phar_wrapper_rename(php_stream_wrapper *wrapper, const char *url_from
782782
}
783783
if (PHAR_G(readonly) && (!pto || !pto->is_data)) {
784784
php_url_free(resource_from);
785+
php_url_free(resource_to);
785786
php_error_docref(NULL, E_WARNING, "phar error: Write operations disabled by the php.ini setting phar.readonly");
786787
return 0;
787788
}

0 commit comments

Comments
 (0)