Commit 957aac2bc3c for php

commit 957aac2bc3c3edba12d27e81e9cdaeeb273727b4
Merge: 30bf8e7e412 026bb4e1ffa
Author: Daniel Scherzer <daniel.e.scherzer+phpf@gmail.com>
Date:   Fri Oct 2 18:29:47 2026 -0700

    Merge branch 'PHP-8.4' into PHP-8.5

    * PHP-8.4:
      ext/soap: fix leak when `load_wsdl_ex()` fails to load (#24066)

diff --cc NEWS
index 3974e4808af,326a9fe7986..f14d47d2aca
--- a/NEWS
+++ b/NEWS
@@@ -185,7 -182,18 +185,8 @@@ PH
  - SOAP:
    . Fixed bug GH-22895 (Heap use-after-free while encoding a Traversable with
      an illegal key). (David Carlier)
+   . Fixed memory leak when load_wsdl_ex() failed to load. (DanielEScherzer)

 -- Sockets:
 -  . Fixed socket_select() silently truncating sets larger than FD_SETSIZE on
 -    Windows. (David Carlier)
 -
 -- SPL:
 -  . Fixed SplFixedArray::setSize() doing nothing on subclasses whose
 -    constructor does not call parent::__construct(). (Marc Bennewitz)
 -  . Fixed memory leak when __construct(), __wakeup() or __unserialize() is
 -    called from an element destructor during setSize(0). (Marc Bennewitz)
 -
  - SQLite:
    . Fixed a crash when SQLite3::close() is called from a userland callback.
      (Ilia Alshanetsky)
diff --cc ext/soap/php_sdl.c
index 566b8dc1e50,e53da38c33f..7a1ff08752e
--- a/ext/soap/php_sdl.c
+++ b/ext/soap/php_sdl.c
@@@ -369,7 -364,12 +369,12 @@@ static void load_wsdl_ex(zval *this_ptr
  			xmlAttrPtr tmp = get_attribute(trav->properties, "location");
  			if (tmp) {
  				xmlChar *uri = schema_location_construct_uri(tmp);
- 				load_wsdl_ex(this_ptr, (char*)uri, ctx, true);
+ 				zend_try {
 -					load_wsdl_ex(this_ptr, (char*)uri, ctx, 1);
++					load_wsdl_ex(this_ptr, (char*)uri, ctx, true);
+ 				} zend_catch {
+ 					xmlFree(uri);
+ 					zend_bailout();
+ 				} zend_end_try();
  				xmlFree(uri);
  			}