silent startup errors msg about deprecated (or other) warnings
| From: | Pierre Joye | Date: | Sun, 30 Aug 2009 21:06:10 +0000 |
| Subject: | silent startup errors msg about deprecated (or other) warnings | ||
| Groups: | php.internals | ||
| Request: | Send a blank email to internals+get-45436@lists.php.net to get a copy of this message | ||
Hi,
While trying to fix some tests, I found that display_startup_errors is
ignored by some startup errors like deprecated ini settings. Using:
php -d display_startup_errors=0 -d safe_mode=1 foo.php
a deprecated warning will be reaised. I think it is not the expected
behavior and consider that as a bug.
The problem is that we try to log the message and if not log backed
are available, we fall back to the sapi's log_message. In case of CLI,
it is a simple fprintf to STDERR. This simple patch should fix the
problem http://pastie.org/599790.
Any objection to the idea? I can adapt it to the other SAPI if
necessary as well as update the affected tests (like
putenv_err1.phpt).
Cheers,
--
Pierre
http://blog.thepimp.net | http://www.libgd.org