text boolean ini options set with -d do not work (on/off)
| Bug #22844 | text boolean ini options set with -d do not work (on/off) | ||||
|---|---|---|---|---|---|
| Submitted: | 2003-03-24 04:55 UTC | Modified: | 2003-03-24 17:35 UTC | ||
| From: | gk at proliberty dot com | Assigned: | |||
| Status: | Closed | Package: | CGI/CLI related | ||
| PHP Version: | 4.3.2-RC | OS: | linux RH 7.2 | ||
| Private report: | No | CVE-ID: | None | ||
[2003-03-24 04:55 UTC] gk at proliberty dot com
In my php.ini file, I have: display_errors=On display_startup_errors=On In Bug #22796, I noted that display_startup_errors=On is required for proper error display using -r option; however this is a separate problem: errors not displayed if display_startup_error or display_errors is set to ANY value, with ini_set() or on the command line I demonstrate below with -d switch: [greg@p3 junk]$ php -d display_startup_errors=On -r "f();" [greg@p3 junk]$ php -d display_startup_errors=Off -r "f();" [greg@p3 junk]$ php -r "f();" Fatal error: Call to undefined function: f() in Command line code on line 1 [greg@p3 junk]$ php -d display_errors=Off -r "f();" [greg@p3 junk]$ php -d display_errors=On -r "f();" The same problem occurs if call ini_set() instead of using -d option: #FILE: junk.php <?php ini_set("display_errors","On"); ini_set("display_startup_errors","On"); f(); ?> Now, if you use boolean value instead of On/Off, it appears that if EITHER variable is set to 1, errors work but if EITHER is set to 0, they don't: [greg@p3 junk]$ php -d display_errors=0 -r "f();" [greg@p3 junk]$ php -d display_errors=1 -r "f();" Fatal error: Call to undefined function: f() in Command line code on line 1 [greg@p3 junk]$ php -d display_errors=On -r "f();" [greg@p3 junk]$ php -d display_startup_errors=1 -r "f();" Fatal error: Call to undefined function: f() in Command line code on line 1 [greg@p3 junk]$ php -d display_startup_errors=0 -r "f();" [greg@p3 junk]$
Patches
Pull Requests
History
AllCommentsChangesGit/SVN commits
[2003-03-24 05:05 UTC] sniper@php.net
[2003-03-24 07:58 UTC] iliaa@php.net
[2003-03-24 13:52 UTC] gk at proliberty dot com
[2003-03-24 17:08 UTC] gk at proliberty dot com
[2003-03-24 17:35 UTC] iliaa@php.net