php-src/ext/snmp
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 Use "must not" instead of "cannot" wording 2024-08-21 21:12:17 +01:00
config.m4 Update ext/mbstring and ext/snmp dependencies (#15469) 2024-08-17 21:11:28 +02:00
config.w32 Update ext/mbstring and ext/snmp dependencies (#15469) 2024-08-17 21:11:28 +02:00
CREDITS * added detection and walkaround for net-snmp library bug (net-snmp BUGid 2027834) 2011-04-05 12:20:35 +00:00
php_snmp.h Declare ext/snmp constants in stubs (#9113) 2022-07-26 14:48:16 +02:00
snmp_arginfo.h Fix registration of internal readonly child classes (#15459) 2024-08-24 12:36:54 +02:00
snmp.c Use "must not" instead of "cannot" wording 2024-08-21 21:12:17 +01:00
snmp.stub.php Fix class constant and property ID generation for the manual (#14249) 2024-05-17 20:30:16 +02:00