Index: chrome/browser/profiles/off_the_record_profile_impl.cc |
diff --git a/chrome/browser/profiles/off_the_record_profile_impl.cc b/chrome/browser/profiles/off_the_record_profile_impl.cc |
index 5d6db0a3efae97ee2f5960eb5a2c3239143fddc6..29c84cd8ad112d526a649e2a828865ca9194e5e7 100644 |
--- a/chrome/browser/profiles/off_the_record_profile_impl.cc |
+++ b/chrome/browser/profiles/off_the_record_profile_impl.cc |
@@ -416,8 +416,16 @@ chrome_browser_net::Predictor* OffTheRecordProfileImpl::GetNetworkPredictor() { |
return NULL; |
} |
-void OffTheRecordProfileImpl::ClearNetworkingHistorySince(base::Time time) { |
- // No need to do anything here, our transport security state is read-only. |
+void OffTheRecordProfileImpl::ClearNetworkingHistorySince( |
+ base::Time time, |
+ const base::Closure& completion) { |
+ // Nothing to do here, our transport security state is read-only. |
+ // Still, fire the callback to indicate we have finished, otherwise the |
+ // BrowsingDataRemover will never be destroyed and the dialog will never be |
+ // closed. We must do this asynchronously in order to avoid reentrancy issues. |
+ if (!completion.is_null()) { |
+ BrowserThread::PostTask(BrowserThread::UI, FROM_HERE, completion); |
+ } |
} |
GURL OffTheRecordProfileImpl::GetHomePage() { |