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

Unified Diff: content/browser/download/base_file_mac.cc

Issue 11238044: Refactor BaseFile methods to return a DownloadInterruptReason instead of a net::Error. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 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: content/browser/download/base_file_mac.cc
diff --git a/content/browser/download/base_file_mac.cc b/content/browser/download/base_file_mac.cc
new file mode 100644
index 0000000000000000000000000000000000000000..f286bf722cfacd32243030acbb90def19b51b554
--- /dev/null
+++ b/content/browser/download/base_file_mac.cc
@@ -0,0 +1,17 @@
+// Copyright (c) 2012 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#include "content/browser/download/base_file.h"
+
+#include "content/browser/download/file_metadata_mac.h"
+#include "content/public/browser/browser_thread.h"
+
+content::DownloadInterruptReason BaseFile::AnnotateWithSourceInformation() {
+ DCHECK(content::BrowserThread::CurrentlyOn(content::BrowserThread::FILE));
+ DCHECK(!detached_);
+
+ content::AddQuarantineMetadataToFile(full_path_, source_url_, referrer_url_);
+ content::AddOriginMetadataToFile(full_path_, source_url_, referrer_url_);
+ return content::DOWNLOAD_INTERRUPT_REASON_NONE;
+}

Powered by Google App Engine
This is Rietveld 408576698