Skip to content

Unexpected null pointer in Zend/zend_smart_str.h #15137

Closed
@YuanchengJiang

Description

@YuanchengJiang

Description

The following code:

<?php
$cdata = new DOMText;
var_dump($GLOBALS);

Resulted in this output:

/php-src/Zend/zend_smart_str.h:177:41: runtime error: null pointer passed as argument 1, which is declared to never be null
/usr/include/string.h:408:33: note: nonnull attribute specified here
SUMMARY: UndefinedBehaviorSanitizer: undefined-behavior /php-src/Zend/zend_smart_str.h:177:41 in 

PHP Version

PHP 8.4.0-dev

Operating System

ubuntu 22.04

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions