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

Unified Diff: chrome/browser/history/download_database.cc

Issue 6043: Added dangerous download prompting. (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 12 years, 2 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
Index: chrome/browser/history/download_database.cc
===================================================================
--- chrome/browser/history/download_database.cc (revision 2758)
+++ chrome/browser/history/download_database.cc (working copy)
@@ -93,6 +93,20 @@
return statement->step() == SQLITE_DONE;
}
+bool DownloadDatabase::UpdateDownloadPath(const std::wstring& path,
+ DownloadID db_handle) {
+ DCHECK(db_handle > 0);
+ SQLITE_UNIQUE_STATEMENT(statement, GetStatementCache(),
+ "UPDATE downloads "
+ "SET full_path=? WHERE id=?");
+ if (!statement.is_valid())
+ return false;
+
+ statement->bind_wstring(0, path);
+ statement->bind_int64(1, db_handle);
+ return statement->step() == SQLITE_DONE;
+}
+
int64 DownloadDatabase::CreateDownload(const DownloadCreateInfo& info) {
SQLITE_UNIQUE_STATEMENT(statement, GetStatementCache(),
"INSERT INTO downloads "

Powered by Google App Engine
This is Rietveld 408576698