[php-src] Issue #21058: undefined behavior in basic_functions.c

From: Date: Wed, 28 Jan 2026 12:47:24 +0000
Subject: [php-src] Issue #21058: undefined behavior in basic_functions.c
Groups: php.bugs 
Request: Send a blank email to php-bugs+get-251613@lists.php.net to get a copy of this message
Issue: https://github.com/php/php-src/issues/21058 Author: chongwick ### Description The following code: ```php <?php $v_6790 = getcwd(); $v_6796 = 'Hello World!'; $v_6807 = var_dump($v_6796,); $v_6794 = 3; $v_6812 = error_log($v_6807,$v_6794,$v_6807,); ``` Resulted in this output: ``` string(12) "Hello World!" Deprecated: error_log(): Passing null to parameter #1 ($message) of type string is deprecated in /home/w023dtc/treebugs/0eebb710140f44c53dfd.php.er on line 6 /home/w023dtc/nightly_php/php-src/ext/standard/basic_functions.c:1372:13: runtime error: member access within null pointer of type 'const zend_string' (aka 'const struct _zend_string') SUMMARY: UndefinedBehaviorSanitizer: undefined-behavior /home/w023dtc/nightly_php/php-src/ext/standard/basic_functions.c:1372:13 ``` ### PHP Version ```plain nightly ``` ### Operating System ubuntu 22.04

« previous php.bugs (#251613) next »