diff options
author | georgey@chromium.org <georgey@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-04-30 22:51:46 +0000 |
---|---|---|
committer | georgey@chromium.org <georgey@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-04-30 22:51:46 +0000 |
commit | 024f2f060ad0bdab9b0e8008973bde64bf04bd28 (patch) | |
tree | 7b0241021bb0731f41d387e0d42a6db6127a6008 /chrome/browser/history/history_backend.cc | |
parent | 2afe4b18b33efe4751d04d0cfc7a512e746654ad (diff) | |
download | chromium_src-024f2f060ad0bdab9b0e8008973bde64bf04bd28.zip chromium_src-024f2f060ad0bdab9b0e8008973bde64bf04bd28.tar.gz chromium_src-024f2f060ad0bdab9b0e8008973bde64bf04bd28.tar.bz2 |
Fix for bug 37909: "Clear All" in incognito downloads window will clear all, including non-incognito downloads.
BUG=37909
TEST=Open regular and incognito download pages. "Clear all" on incognito will clear all, but pending downloads. In regular window it would clear all, but pending and incognito.
Review URL: http://codereview.chromium.org/1807007
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@46141 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/history/history_backend.cc')
-rw-r--r-- | chrome/browser/history/history_backend.cc | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/chrome/browser/history/history_backend.cc b/chrome/browser/history/history_backend.cc index 4be006a..caaec96 100644 --- a/chrome/browser/history/history_backend.cc +++ b/chrome/browser/history/history_backend.cc @@ -1040,6 +1040,15 @@ void HistoryBackend::QueryDownloads( request->ForwardResult(DownloadQueryRequest::TupleType(&request->value)); } +// Clean up entries that has been corrupted (because of the crash, for example). +void HistoryBackend::CleanUpInProgressEntries() { + if (db_.get()) { + // If some "in progress" entries were not updated when Chrome exited, they + // need to be cleaned up. + db_->CleanUpInProgressEntries(); + } +} + // Update a particular download entry. void HistoryBackend::UpdateDownload(int64 received_bytes, int32 state, |