#44936 [Ctl->Fbk]: BC break: ini_set() changes 'access' value
ID: 44936
Updated by: stas@php.net
Reported By: romain dot dorgueil at sensio dot net
-Status: Critical
+Status: Feedback
Bug Type: *General Issues
Operating System: linux 2.6.22-14
PHP Version: PHP_5_2 only
Assigned To: iliaa
Previous Comments:
------------------------------------------------------------------------
[2008-09-08 20:06:18] stas@php.net
Why it is a problem? As far as I can see, there was a change that now
uses some previously unused bits in the access mask, but why it is a
bug? Does something that worked before doesn't work now?
------------------------------------------------------------------------
[2008-05-26 20:31:31] jani@php.net
Ilia, I think this is the patch that causes the side-effect:
http://cvs.php.net/viewvc.cgi/ZendEngine2/zend_ini.c?r1=1.39.2.2.2.26&r2=1.39.2.2.2.27&pathrev=PHP_5_2
------------------------------------------------------------------------
[2008-05-07 18:11:18] romain dot dorgueil at sensio dot net
Description:
------------
ini_set changes the 'access' parameter of configuration entry to 63
without any reason.
This behaviour did not exist in previous versions and is very easy to
reproduce. It is not documented and not in the php 5.6.3 changelog.
Reproduce code:
---------------
<?php
define('CONFIG_ENTRY', 'magic_quotes_runtime');
function dumpini()
{
$configs = ini_get_all();
echo 'access value: '.$configs[CONFIG_ENTRY]['access']."\n";
}
dumpini();
echo 'ini_set(\''.CONFIG_ENTRY.'\', 0);'."\n";
ini_set(CONFIG_ENTRY, 0);
dumpini();
Expected result:
----------------
access value: 7
ini_set('magic_quotes_runtime', 0);
access value: 7
Actual result:
--------------
access value: 7
ini_set('magic_quotes_runtime', 0);
access value: 63
------------------------------------------------------------------------
--
Edit this bug report at http://bugs.php.net/?id=44936&edit=1
Thread (6 messages)