/
usr
/
local
/
lsws
/
phpbuild
/
php-8.0.7
/
Zend
/
tests
/
File Upload :
llllll
Current File: //usr/local/lsws/phpbuild/php-8.0.7/Zend/tests/bug71572.phpt
--TEST-- Bug #71572: String offset assignment from an empty string inserts null byte --FILE-- <?php $str = "abc"; try { var_dump($str[0] = ""); } catch (\Error $e) { echo $e->getMessage() . \PHP_EOL; } try { var_dump($str[1] = ""); } catch (\Error $e) { echo $e->getMessage() . \PHP_EOL; } try { var_dump($str[3] = ""); } catch (\Error $e) { echo $e->getMessage() . \PHP_EOL; } try { var_dump($str[10] = ""); } catch (\Error $e) { echo $e->getMessage() . \PHP_EOL; } var_dump($str); ?> --EXPECT-- Cannot assign an empty string to a string offset Cannot assign an empty string to a string offset Cannot assign an empty string to a string offset Cannot assign an empty string to a string offset string(3) "abc"
Copyright ©2k19 -
Hexid
|
Tex7ure