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

Unified Diff: chrome/browser/extensions/extension_disabled_infobar_delegate.cc

Issue 7003068: Fix crash when you uninstall a permissions-upgrade disabled extension. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 9 years, 6 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 | chrome/browser/extensions/extension_management_browsertest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/extensions/extension_disabled_infobar_delegate.cc
diff --git a/chrome/browser/extensions/extension_disabled_infobar_delegate.cc b/chrome/browser/extensions/extension_disabled_infobar_delegate.cc
index 94cbde5a778b5c6e4bf1104a88acf4bc11cbbf66..66b2a298b0dedeafd63f517d3d0382155319e700 100644
--- a/chrome/browser/extensions/extension_disabled_infobar_delegate.cc
+++ b/chrome/browser/extensions/extension_disabled_infobar_delegate.cc
@@ -158,8 +158,9 @@ void ExtensionDisabledInfobarDelegate::Observe(
} else {
DCHECK_EQ(NotificationType::EXTENSION_UNLOADED, type.value);
UnloadedExtensionInfo* info = Details<UnloadedExtensionInfo>(details).ptr();
- extension = (info->reason == UnloadedExtensionInfo::DISABLE) ?
- info->extension : NULL;
+ if (info->reason == UnloadedExtensionInfo::DISABLE ||
Mihai Parparita -not on Chrome 2011/06/08 23:20:44 Won't this leave extension uninitialized if it's n
+ info->reason == UnloadedExtensionInfo::UNINSTALL)
+ extension = info->extension;
}
if (extension == extension_)
tab_contents_->RemoveInfoBar(this);
« no previous file with comments | « no previous file | chrome/browser/extensions/extension_management_browsertest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698