php-src/Zend/tests/exception_024.phpt
Tyson Andre 07db64156e [RFC] Make string length for getTraceAsString() configurable
Add a `zend.exception_string_param_max_len` ini setting.
(same suffix as `log_errors_max_len`)

Allow values between 0 and 1000000 bytes.
For example, with zend.exception_string_param_max_len=0,
"" would represent the empty string, and "..." would represent something
longer than the empty string.
Previously, this was hardcoded as exactly 15 bytes.

Discussion: https://externals.io/message/110717

Closes GH-5769
2020-07-25 09:50:57 -04:00

20 lines
365 B
PHP

--TEST--
zend.exception_string_param_max_len ini setting
--INI--
zend.exception_string_param_max_len = 23
--FILE--
<?php
function main($arg) {
throw new Exception();
}
main('123456789012345678901234567890');
?>
--EXPECTF--
Fatal error: Uncaught Exception in %s:%d
Stack trace:
#0 %s(%d): main('12345678901234567890123...')
#1 {main}
thrown in %s on line %d