mirror of
https://github.com/php/php-src.git
synced 2024-09-23 10:57:26 +00:00
254a5914ad
`SplFileInfo::__construct()` has to expect a path instead of a string, analogous to `SplFileObject::__construct()`.
9 lines
263 B
PHP
9 lines
263 B
PHP
--TEST--
|
|
Bug #77431 (SplFileInfo::__construct() accepts NUL bytes)
|
|
--FILE--
|
|
<?php
|
|
new SplFileInfo("bad\0good");
|
|
?>
|
|
--EXPECTF--
|
|
Fatal error: Uncaught TypeError: SplFileInfo::__construct() expects parameter 1 to be a valid path, string given in %s:%d
|
|
Stack trace:%A
|