Skip to content

Segmentation fault (access null pointer) in Zend/zend_operators.c:2495 #16358

Closed
@YuanchengJiang

Description

@YuanchengJiang

Description

The following code:

<?php
class test_class {
static protected function test_func4() {
}
}
if (is_callable(array('test_class','test_func4'))) {
test_class::test_func4();
}

Resulted in this output:

/php-src/Zend/zend_operators.c:2495:31: runtime error: member access within null pointer of type 'const zend_class_entry' (aka 'const struct _zend_class_entry')
SUMMARY: UndefinedBehaviorSanitizer: undefined-behavior /php-src/Zend/zend_operators.c:2495:31

To reproduce:

-d "opcache.jit_hot_func=1" -d "zend_extension=/php-src/modules/opcache.so" -d "opcache.enable_cli=1" -d "opcache.jit=1234"

PHP Version

nightly

Operating System

ubuntu 22.04

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions