Index: includes/bootstrap.inc
===================================================================
RCS file: /cvs/drupal/drupal/includes/bootstrap.inc,v
retrieving revision 1.239
diff -u -p -r1.239 bootstrap.inc
--- includes/bootstrap.inc	19 Oct 2008 21:27:13 -0000	1.239
+++ includes/bootstrap.inc	11 Oct 2008 09:14:21 -0000
@@ -1024,7 +1024,7 @@ function drupal_bootstrap($phase = NULL)
   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), $completed_phase = -1;
 
   if (isset($phase) && $phase > $completed_phase) {
-    while ($phases) {
+    while ($phases && $phase > $completed_phase) {
       $current_phase = array_shift($phases);
       _drupal_bootstrap($current_phase);
       $completed_phase = $current_phase;
