php-src/ext/xml
Máté Kocsis 8d12f666ae
Fix registration of internal readonly child classes (#15459)
Currently, internal classes are registered with the following code:

INIT_CLASS_ENTRY(ce, "InternalClass", class_InternalClass_methods);
class_entry = zend_register_internal_class_ex(&ce, NULL);
class_entry->ce_flags |= ...;

This has worked well so far, except if InternalClass is readonly. It is because some inheritance checks are run by zend_register_internal_class_ex before ZEND_ACC_READONLY_CLASS is added to ce_flags.

The issue is fixed by adding a zend_register_internal_class_with_flags() zend API function that stubs can use from now on. This function makes sure to add the flags before running any checks. Since the new API is not available in lower PHP versions, gen_stub.php has to keep support for the existing API for PHP 8.3 and below.
2024-08-24 12:36:54 +02:00
..
tests ext/xml: Add an explicit test case about unsetting a handler with empty string 2024-08-11 15:00:27 +02:00
compat.c Stop using reserved names 2024-07-06 13:49:45 -07:00
config.m4 Sync HAVE_<extension> help texts (#15167) 2024-08-02 01:41:47 +02:00
config.w32 Sync HAVE_<extension> help texts (#15167) 2024-08-02 01:41:47 +02:00
CREDITS
expat_compat.h Avoid function pointer cast to preserve ability to do CFI 2024-07-06 13:49:45 -07:00
php_xml.h Implement request #68325: parse huge option for xml_parser_create (#12256) 2023-10-22 16:44:49 +02:00
xml.c ext/xml: Deprecate xml_set_object() and passing non-callable strings as handlers (#15293) 2024-08-08 23:37:49 +01:00
xml.stub.php ext/xml: Deprecate xml_set_object() and passing non-callable strings as handlers (#15293) 2024-08-08 23:37:49 +01:00
xml_arginfo.h Fix registration of internal readonly child classes (#15459) 2024-08-24 12:36:54 +02:00