[php-src] master: Merge branch 'PHP-8.4' into PHP-8.5

From: Date: Mon, 17 Aug 2026 18:49:55 +0000
Subject: [php-src] master: Merge branch 'PHP-8.4' into PHP-8.5
Groups: php.cvs 
Request: Send a blank email to php-cvs+get-140782@lists.php.net to get a copy of this message
Author: Weilin Du (LamentXU123) Date: 2026-08-18T02:42:00+08:00 Commit: https://github.com/php/php-src/commit/be4b987cb3f083ef6ca0dae72873cc7eb270ee94 Raw diff: https://github.com/php/php-src/commit/be4b987cb3f083ef6ca0dae72873cc7eb270ee94.diff Merge branch 'PHP-8.4' into PHP-8.5 * PHP-8.4: Fix IntlGregorianCalendar double-free of an adopted TimeZone (#23321) Changed paths: M NEWS M ext/intl/calendar/gregoriancalendar_methods.cpp Diff: diff --git a/NEWS b/NEWS index baea08f757f5..081461b539ed 100644 --- a/NEWS +++ b/NEWS @@ -12,6 +12,10 @@ PHP NEWS . Fixed a crash in DOMXPath when a php:function callback receives a nodeset and a later callback returns a node from another document. (iliaal) +- Intl: + . Fixed a double-free when IntlGregorianCalendar construction fails after + the ICU constructor adopts the TimeZone. (iliaal) + - Opcache: . Fixed opcache.protect_memory race under ZTS. (realFlowControl) diff --git a/ext/intl/calendar/gregoriancalendar_methods.cpp b/ext/intl/calendar/gregoriancalendar_methods.cpp index bf05cd8ad3f0..9910512df1d9 100644 --- a/ext/intl/calendar/gregoriancalendar_methods.cpp +++ b/ext/intl/calendar/gregoriancalendar_methods.cpp @@ -165,7 +165,6 @@ static void _php_intlgregcal_constructor_body(INTERNAL_FUNCTION_PARAMETERS, bool if (U_FAILURE(status)) { intl_error_set(NULL, status, "error creating ICU " "GregorianCalendar from time zone and locale"); - delete tz; if (!is_constructor) { zval_ptr_dtor(return_value); RETVAL_NULL();

« previous php.cvs (#140782) next »