]> granicus.if.org Git - php/commitdiff
Fix bug #48880
authorRasmus Lerdorf <rasmus@php.net>
Fri, 31 Jul 2009 21:09:45 +0000 (21:09 +0000)
committerRasmus Lerdorf <rasmus@php.net>
Fri, 31 Jul 2009 21:09:45 +0000 (21:09 +0000)
The ini entry was being corrupted because it wasn't being set
on the ACTIVATE and DEACTIVATE stages.

NEWS
main/fopen_wrappers.c

diff --git a/NEWS b/NEWS
index 59282e885477a3d847d40047bdf53ec959b8101a..97f1a50577c6ef387dd6fe40f5fa3f95d4b783f8 100644 (file)
--- a/NEWS
+++ b/NEWS
@@ -8,6 +8,7 @@
 - Fixed signature generation/validation for zip archives in ext/phar. (Greg)
 - Fixed memory leak in stream_is_local(). (Felipe)
 
+- Fixed bug #48880 (Random Appearing open_basedir problem). (Rasmus+Gwynne)
 - Fixed bug #49108 (2nd scan_dir produces seg fault). (Felipe)
 - Fixed bug #49065 ("disable_functions" php.ini option does not work on 
   Zend extensions). (Stas)
index c9c7545871840ad3e036575652826b6d00ced166..7c6dc4f7d5a4e8cecac60fbed2ff6cc4703bc519 100644 (file)
@@ -93,7 +93,7 @@ PHPAPI ZEND_INI_MH(OnUpdateBaseDir)
 
        p = (char **) (base + (size_t) mh_arg1);
 
-       if (stage == PHP_INI_STAGE_STARTUP || stage == PHP_INI_STAGE_SHUTDOWN) {
+       if (stage == PHP_INI_STAGE_STARTUP || stage == PHP_INI_STAGE_SHUTDOWN || stage == PHP_INI_STAGE_ACTIVATE || stage == PHP_INI_STAGE_DEACTIVATE) {
                /* We're in a PHP_INI_SYSTEM context, no restrictions */
                *p = new_value;
                return SUCCESS;