Index: includes/bootstrap.inc =================================================================== RCS file: /cvs/drupal/drupal/includes/bootstrap.inc,v retrieving revision 1.238 diff -u -p -r1.238 bootstrap.inc --- includes/bootstrap.inc 16 Oct 2008 21:16:06 -0000 1.238 +++ includes/bootstrap.inc 11 Oct 2008 06:11:05 -0000 @@ -125,26 +125,31 @@ define('DRUPAL_BOOTSTRAP_ACCESS', 3); define('DRUPAL_BOOTSTRAP_SESSION', 4); /** - * Sixth bootstrap phase: load bootstrap.inc and module.inc, start + * Sixth bootstrap phase: initialize the variable system. + */ +define('DRUPAL_BOOTSTRAP_VARIABLE', 5); + +/** + * Seventh bootstrap phase: load bootstrap.inc and module.inc, start * the variable system and try to serve a page from the cache. */ -define('DRUPAL_BOOTSTRAP_LATE_PAGE_CACHE', 5); +define('DRUPAL_BOOTSTRAP_LATE_PAGE_CACHE', 6); /** - * Seventh bootstrap phase: find out language of the page. + * Eighth bootstrap phase: find out language of the page. */ -define('DRUPAL_BOOTSTRAP_LANGUAGE', 6); +define('DRUPAL_BOOTSTRAP_LANGUAGE', 7); /** - * Eighth bootstrap phase: set $_GET['q'] to Drupal path of request. + * Nineth bootstrap phase: set $_GET['q'] to Drupal path of request. */ -define('DRUPAL_BOOTSTRAP_PATH', 7); +define('DRUPAL_BOOTSTRAP_PATH', 8); /** * Final bootstrap phase: Drupal is fully loaded; validate and fix * input data. */ -define('DRUPAL_BOOTSTRAP_FULL', 8); +define('DRUPAL_BOOTSTRAP_FULL', 9); /** * Role ID for anonymous users; should match what's in the "role" table. @@ -1021,7 +1026,7 @@ function drupal_anonymous_user($session * DRUPAL_BOOTSTRAP_FULL: Drupal is fully loaded, validate and fix input data. */ function drupal_bootstrap($phase) { - static $phases = array(DRUPAL_BOOTSTRAP_CONFIGURATION, DRUPAL_BOOTSTRAP_EARLY_PAGE_CACHE, DRUPAL_BOOTSTRAP_DATABASE, DRUPAL_BOOTSTRAP_ACCESS, DRUPAL_BOOTSTRAP_SESSION, DRUPAL_BOOTSTRAP_LATE_PAGE_CACHE, DRUPAL_BOOTSTRAP_LANGUAGE, DRUPAL_BOOTSTRAP_PATH, DRUPAL_BOOTSTRAP_FULL), $phase_index = 0; + static $phases = array(DRUPAL_BOOTSTRAP_CONFIGURATION, DRUPAL_BOOTSTRAP_EARLY_PAGE_CACHE, DRUPAL_BOOTSTRAP_DATABASE, DRUPAL_BOOTSTRAP_ACCESS, DRUPAL_BOOTSTRAP_SESSION, DRUPAL_BOOTSTRAP_VARIABLE, DRUPAL_BOOTSTRAP_LATE_PAGE_CACHE, DRUPAL_BOOTSTRAP_LANGUAGE, DRUPAL_BOOTSTRAP_PATH, DRUPAL_BOOTSTRAP_FULL), $phase_index = 0; while ($phase >= $phase_index && isset($phases[$phase_index])) { $current_phase = $phases[$phase_index]; @@ -1095,9 +1100,12 @@ function _drupal_bootstrap($phase) { session_start(); break; - case DRUPAL_BOOTSTRAP_LATE_PAGE_CACHE: + case DRUPAL_BOOTSTRAP_VARIABLE: // Initialize configuration variables, using values from settings.php if available. $conf = variable_init(isset($conf) ? $conf : array()); + break; + + case DRUPAL_BOOTSTRAP_LATE_PAGE_CACHE: // Load module handling. require_once DRUPAL_ROOT . '/includes/module.inc'; $cache_mode = variable_get('cache', CACHE_DISABLED);