| Index: chrome/browser/captive_portal/captive_portal_browsertest.cc
 | 
| diff --git a/chrome/browser/captive_portal/captive_portal_browsertest.cc b/chrome/browser/captive_portal/captive_portal_browsertest.cc
 | 
| index 1bca5ec4416d7317a4b8ae93533fd5597fe02431..d6a50c68239aadab9135dade83f3284392b21b7a 100644
 | 
| --- a/chrome/browser/captive_portal/captive_portal_browsertest.cc
 | 
| +++ b/chrome/browser/captive_portal/captive_portal_browsertest.cc
 | 
| @@ -319,7 +319,7 @@ void URLRequestTimeoutOnDemandJob::MaybeStopWaitingForJobsOnIOThread() {
 | 
|      last_num_jobs_to_wait_for_ = num_jobs_to_wait_for_;
 | 
|      num_jobs_to_wait_for_ = 0;
 | 
|      BrowserThread::PostTask(BrowserThread::UI, FROM_HERE,
 | 
| -                            base::MessageLoop::QuitClosure());
 | 
| +                            base::MessageLoop::QuitWhenIdleClosure());
 | 
|    }
 | 
|  }
 | 
|  
 | 
| @@ -651,7 +651,7 @@ void MultiNavigationObserver::Observe(
 | 
|    if (waiting_for_navigation_ &&
 | 
|        num_navigations_to_wait_for_ == num_navigations_) {
 | 
|      waiting_for_navigation_ = false;
 | 
| -    base::MessageLoopForUI::current()->Quit();
 | 
| +    base::MessageLoopForUI::current()->QuitWhenIdle();
 | 
|    }
 | 
|  }
 | 
|  
 | 
| @@ -741,7 +741,7 @@ void FailLoadsAfterLoginObserver::Observe(
 | 
|        tabs_needing_navigation_.size() ==
 | 
|            tabs_navigated_to_final_destination_.size()) {
 | 
|      waiting_for_navigation_ = false;
 | 
| -    base::MessageLoopForUI::current()->Quit();
 | 
| +    base::MessageLoopForUI::current()->QuitWhenIdle();
 | 
|    }
 | 
|  }
 | 
|  
 | 
| @@ -835,7 +835,7 @@ void CaptivePortalObserver::Observe(
 | 
|    if (waiting_for_result_ &&
 | 
|        num_results_to_wait_for_ == num_results_received_) {
 | 
|      waiting_for_result_ = false;
 | 
| -    base::MessageLoop::current()->Quit();
 | 
| +    base::MessageLoop::current()->QuitWhenIdle();
 | 
|    }
 | 
|  }
 | 
|  
 | 
| 
 |