Index: chrome/browser/plugin_installer.cc |
diff --git a/chrome/browser/plugin_installer.cc b/chrome/browser/plugin_installer.cc |
index f79566211f87cc90e2960f9006b3814380020d66..bcfbecc28a1c8ec5f3d6f4e161b6d66bd7c8f229 100644 |
--- a/chrome/browser/plugin_installer.cc |
+++ b/chrome/browser/plugin_installer.cc |
@@ -150,11 +150,6 @@ void PluginInstaller::OnDownloadUpdated(DownloadItem* download) { |
DownloadCancelled(); |
break; |
} |
- case DownloadItem::REMOVING: { |
- DCHECK_EQ(INSTALLER_STATE_DOWNLOADING, state_); |
- state_ = INSTALLER_STATE_IDLE; |
- break; |
- } |
case DownloadItem::INTERRUPTED: { |
content::DownloadInterruptReason reason = download->GetLastReason(); |
DownloadError(content::InterruptReasonDebugString(reason)); |
@@ -168,7 +163,10 @@ void PluginInstaller::OnDownloadUpdated(DownloadItem* download) { |
download->RemoveObserver(this); |
} |
-void PluginInstaller::OnDownloadOpened(DownloadItem* download) { |
+void PluginInstaller::OnDownloadDestroyed(DownloadItem* download) { |
+ DCHECK_EQ(INSTALLER_STATE_DOWNLOADING, state_); |
+ state_ = INSTALLER_STATE_IDLE; |
+ download->RemoveObserver(this); |
} |
void PluginInstaller::AddObserver(PluginInstallerObserver* observer) { |