| Index: chrome/browser/profiles/profile_impl_io_data.cc
|
| diff --git a/chrome/browser/profiles/profile_impl_io_data.cc b/chrome/browser/profiles/profile_impl_io_data.cc
|
| index 8314f0d5d442c368e5ae1e60cfb79a5268b3cd67..b2ba615cb86229c9fe880a5f20cb63c0278c3028 100644
|
| --- a/chrome/browser/profiles/profile_impl_io_data.cc
|
| +++ b/chrome/browser/profiles/profile_impl_io_data.cc
|
| @@ -56,12 +56,12 @@ ProfileImplIOData::Handle::~Handle() {
|
| if (extensions_request_context_getter_)
|
| extensions_request_context_getter_->CleanupOnUIThread();
|
|
|
| - // TODO(rlp): Remove CHECKs once we have determined the cause for flakiness
|
| - // during predictor shutdown. See http://crosbug.com/20407.
|
| - CHECK(profile_ != NULL);
|
| - PrefService* user_prefs = profile_->GetPrefs();
|
| - CHECK(io_data_->predictor_.get() != NULL);
|
| - io_data_->predictor_->ShutdownOnUIThread(user_prefs);
|
| + if (io_data_->predictor_.get() != NULL) {
|
| + // io_data_->predictor_ might be NULL if Init() was never called
|
| + // (i.e. we shut down before ProfileImpl::DoFinalInit() got called).
|
| + PrefService* user_prefs = profile_->GetPrefs();
|
| + io_data_->predictor_->ShutdownOnUIThread(user_prefs);
|
| + }
|
|
|
| // Clean up all isolated app request contexts.
|
| for (ChromeURLRequestContextGetterMap::iterator iter =
|
|
|