From:             tokul at users dot sourceforge dot net
Operating system: Linux Debian Etch
PHP version:      4CVS-2007-05-07 (snap)
PHP Bug Type:     PHP options/info functions
Bug description:  ini_get does not return default value if variables_order is 
not set

Description:
------------
In PHP 4.x ini_get function does not return default variables_order value,
if it is not set in PHP_INI_ALL locations.

Tested PHP version
* 5.2.0-8 (stock debian etch) - returns EGPCS
* php4-STABLE-200705071630 - returns boolean false
* php5.2-200705071630 - returns EGPCS
* php6.0-200705071630 - returns EGPCS

All snapshots are compiled only with --prefix, --with-config-file-path and
--with-apxs2 options. All use empty php.ini file.

I recommend returning default value instead of false, if configuration
value is not present in configuration file. Or make sure that behavior is
consistent between PHP versions and configuration variables. For example,
if gpc_order is missing in php.ini, ini_get() still returns 'GPC' in php
4.x.

Reproduce code:
---------------
var_dump(ini_get('variables_order'));

Expected result:
----------------
string(5) "EGPCS"

Actual result:
--------------
bool(false)

-- 
Edit bug report at http://bugs.php.net/?id=41317&edit=1
-- 
Try a CVS snapshot (PHP 4.4): 
http://bugs.php.net/fix.php?id=41317&r=trysnapshot44
Try a CVS snapshot (PHP 5.2): 
http://bugs.php.net/fix.php?id=41317&r=trysnapshot52
Try a CVS snapshot (PHP 6.0): 
http://bugs.php.net/fix.php?id=41317&r=trysnapshot60
Fixed in CVS:                 http://bugs.php.net/fix.php?id=41317&r=fixedcvs
Fixed in release:             
http://bugs.php.net/fix.php?id=41317&r=alreadyfixed
Need backtrace:               http://bugs.php.net/fix.php?id=41317&r=needtrace
Need Reproduce Script:        http://bugs.php.net/fix.php?id=41317&r=needscript
Try newer version:            http://bugs.php.net/fix.php?id=41317&r=oldversion
Not developer issue:          http://bugs.php.net/fix.php?id=41317&r=support
Expected behavior:            http://bugs.php.net/fix.php?id=41317&r=notwrong
Not enough info:              
http://bugs.php.net/fix.php?id=41317&r=notenoughinfo
Submitted twice:              
http://bugs.php.net/fix.php?id=41317&r=submittedtwice
register_globals:             http://bugs.php.net/fix.php?id=41317&r=globals
PHP 3 support discontinued:   http://bugs.php.net/fix.php?id=41317&r=php3
Daylight Savings:             http://bugs.php.net/fix.php?id=41317&r=dst
IIS Stability:                http://bugs.php.net/fix.php?id=41317&r=isapi
Install GNU Sed:              http://bugs.php.net/fix.php?id=41317&r=gnused
Floating point limitations:   http://bugs.php.net/fix.php?id=41317&r=float
No Zend Extensions:           http://bugs.php.net/fix.php?id=41317&r=nozend
MySQL Configuration Error:    http://bugs.php.net/fix.php?id=41317&r=mysqlcfg

Reply via email to