Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(64)

Unified Diff: chrome/browser/net/chrome_url_request_context.cc

Issue 2819072: Fixed extension sync-related crash in ChromeUrlRequestContext (Closed)
Patch Set: Addressed erikkay's comments Created 10 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/net/chrome_url_request_context.cc
diff --git a/chrome/browser/net/chrome_url_request_context.cc b/chrome/browser/net/chrome_url_request_context.cc
index a83789378a9a9a959944c2848dd77daf6c5ded37..a01dd246235c67a5ab44b6c6d023dc8fbfbf025e 100644
--- a/chrome/browser/net/chrome_url_request_context.cc
+++ b/chrome/browser/net/chrome_url_request_context.cc
@@ -841,8 +841,15 @@ void ChromeURLRequestContext::OnUnloadedExtension(const std::string& id) {
if (is_off_the_record_)
return;
ExtensionInfoMap::iterator iter = extension_info_.find(id);
- DCHECK(iter != extension_info_.end());
- extension_info_.erase(iter);
+ if (iter != extension_info_.end()) {
+ extension_info_.erase(iter);
+ } else {
+ // NOTE: This can currently happen if we receive multiple unload
+ // notifications, e.g. setting incognito-enabled state for a
+ // disabled extension (e.g., via sync). See
+ // http://code.google.com/p/chromium/issues/detail?id=50582 .
+ NOTREACHED() << id;
+ }
}
bool ChromeURLRequestContext::AreCookiesEnabled() const {
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698