mirror of
https://github.com/php/php-src.git
synced 2025-08-15 21:48:51 +02:00
Use unsigned int instead of int for refcount for libxml objects (#15247)
This commit is contained in:
parent
0c7cd92414
commit
a0c29f0889
3 changed files with 5 additions and 4 deletions
|
@ -301,6 +301,7 @@ PHP 8.4 INTERNALS UPGRADE NOTES
|
|||
- Added php_libxml_uses_internal_errors().
|
||||
- Added a way to override document handlers (e.g. serialization) with
|
||||
php_libxml_document_handlers.
|
||||
- Changed the refcount fields from int to unsigned int.
|
||||
|
||||
e. ext/date
|
||||
- Added the php_format_date_ex() API to format instances of php_date_obj.
|
||||
|
|
|
@ -1243,7 +1243,7 @@ PHP_METHOD(DOMDocument, __construct)
|
|||
dom_object *intern;
|
||||
char *encoding, *version = NULL;
|
||||
size_t encoding_len = 0, version_len = 0;
|
||||
int refcount;
|
||||
unsigned int refcount;
|
||||
|
||||
if (zend_parse_parameters(ZEND_NUM_ARGS(), "|ss", &version, &version_len, &encoding, &encoding_len) == FAILURE) {
|
||||
RETURN_THROWS();
|
||||
|
@ -1476,7 +1476,7 @@ static void php_dom_finish_loading_document(zval *this, zval *return_value, xmlD
|
|||
php_libxml_decrement_node_ptr((php_libxml_node_object *) intern);
|
||||
doc_prop = intern->document->doc_props;
|
||||
intern->document->doc_props = NULL;
|
||||
int refcount = php_libxml_decrement_doc_ref((php_libxml_node_object *)intern);
|
||||
unsigned int refcount = php_libxml_decrement_doc_ref((php_libxml_node_object *)intern);
|
||||
if (refcount != 0) {
|
||||
docp->_private = NULL;
|
||||
}
|
||||
|
|
|
@ -113,14 +113,14 @@ typedef struct _php_libxml_ref_obj {
|
|||
php_libxml_cache_tag cache_tag;
|
||||
php_libxml_private_data_header *private_data;
|
||||
const php_libxml_document_handlers *handlers;
|
||||
int refcount;
|
||||
unsigned int refcount;
|
||||
php_libxml_class_type class_type : 8;
|
||||
php_libxml_quirks_mode quirks_mode : 8;
|
||||
} php_libxml_ref_obj;
|
||||
|
||||
typedef struct _php_libxml_node_ptr {
|
||||
xmlNodePtr node;
|
||||
int refcount;
|
||||
unsigned int refcount;
|
||||
void *_private;
|
||||
} php_libxml_node_ptr;
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue