jani Fri, 04 Sep 2009 11:02:40 +0000 Revision: http://svn.php.net/viewvc?view=revision&revision=288038
Log: I have no idea. This might or might not fix a bug in some branch. At least it works. Changed paths: U php/php-src/branches/PHP_5_3/main/main.c U php/php-src/trunk/main/main.c Modified: php/php-src/branches/PHP_5_3/main/main.c =================================================================== --- php/php-src/branches/PHP_5_3/main/main.c 2009-09-04 10:21:17 UTC (rev 288037) +++ php/php-src/branches/PHP_5_3/main/main.c 2009-09-04 11:02:40 UTC (rev 288038) @@ -1927,33 +1927,6 @@ return FAILURE; } - /* Check for deprecated directives */ - { - static const char *directives[] = { - "define_syslog_variables", - "register_globals", - "register_long_arrays", - "safe_mode", - "magic_quotes_gpc", - "magic_quotes_runtime", - "magic_quotes_sybase", - NULL}; - const char **p = directives; - long val; - - while (*p) { - if (cfg_get_long((char*)*p, &val) == SUCCESS && val) { - zend_error(E_WARNING, "Directive '%s' is deprecated in PHP 5.3 and greater", *p); - } - ++p; - } - - /* This is not too nice, but since its the only one theres no need for extra stuff here */ - if (cfg_get_long("zend.ze1_compatibility_mode", &val) == SUCCESS && val) { - zend_error(E_ERROR, "zend.ze1_compatibility_mode is no longer supported in PHP 5.3 and greater"); - } - } - /* Register PHP core ini entries */ REGISTER_INI_ENTRIES(); @@ -2047,6 +2020,34 @@ shutdown_memory_manager(1, 0 TSRMLS_CC); + /* Check for deprecated directives */ + { + static const char *directives[] = { + "define_syslog_variables", + "register_globals", + "register_long_arrays", + "safe_mode", + "magic_quotes_gpc", + "magic_quotes_runtime", + "magic_quotes_sybase", + NULL + }; + const char **p = directives; + long val; + + while (*p) { + if (cfg_get_long((char*)*p, &val) == SUCCESS && val) { + zend_error(E_WARNING, "Directive '%s' is deprecated in PHP 5.3 and greater", *p); + } + ++p; + } + + /* This is not too nice, but since its the only one theres no need for extra stuff here */ + if (cfg_get_long("zend.ze1_compatibility_mode", &val) == SUCCESS && val) { + zend_error(E_ERROR, "zend.ze1_compatibility_mode is no longer supported in PHP 5.3 and greater"); + } + } + /* we're done */ return SUCCESS; } Modified: php/php-src/trunk/main/main.c =================================================================== --- php/php-src/trunk/main/main.c 2009-09-04 10:21:17 UTC (rev 288037) +++ php/php-src/trunk/main/main.c 2009-09-04 11:02:40 UTC (rev 288038) @@ -1473,7 +1473,7 @@ zend_set_timeout(PG(max_input_time), 1); } - /* Disable realpath cache if safe_mode or open_basedir are set */ + /* Disable realpath cache if open_basedir is set */ if (PG(open_basedir) && *PG(open_basedir)) { CWDG(realpath_cache_size_limit) = 0; } @@ -2040,7 +2040,7 @@ return FAILURE; } - /* Check for deprecated directives */ + /* Check for removed directives */ { static const char *directives[] = { "define_syslog_variables", @@ -2051,13 +2051,14 @@ "magic_quotes_runtime", "magic_quotes_sybase", "zend.ze1_compatibility_mode", - NULL}; + NULL + }; const char **p = directives; long val; while (*p) { if (cfg_get_long((char*)*p, &val) == SUCCESS && val) { - zend_error(E_WARNING, "Directive '%s' is no longer supported in PHP 6 and greater", *p); + zend_error(E_ERROR, "Directive '%s' no longer exist in PHP 6 and greater", *p); } ++p; }
-- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php