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

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

Issue 8468020: Propagate the SafeBrowsing download protection verdict to the DownloadItem. (Closed) Base URL: http://git.chromium.org/git/chromium.git@trunk
Patch Set: Address Ben's comment. Created 9 years, 1 month 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/download_state_info.cc
diff --git a/content/browser/download/download_state_info.cc b/content/browser/download/download_state_info.cc
index c4c17879e15300a4078885fd49d6de6841ee839d..ef539082779a034192e61801d62842584d1015a5 100644
--- a/content/browser/download/download_state_info.cc
+++ b/content/browser/download/download_state_info.cc
@@ -12,7 +12,9 @@ DownloadStateInfo::DownloadStateInfo()
transition_type(content::PAGE_TRANSITION_LINK),
prompt_user_for_save_location(false),
is_dangerous_file(false),
- is_dangerous_url(false) {
+ is_dangerous_url(false),
+ is_dangerous_content(false),
+ needs_quarantine_file(false) {
}
DownloadStateInfo::DownloadStateInfo(
@@ -23,7 +25,9 @@ DownloadStateInfo::DownloadStateInfo(
transition_type(content::PAGE_TRANSITION_LINK),
prompt_user_for_save_location(prompt_user_for_save_location),
is_dangerous_file(false),
- is_dangerous_url(false) {
+ is_dangerous_url(false),
+ is_dangerous_content(false),
+ needs_quarantine_file(false) {
}
DownloadStateInfo::DownloadStateInfo(
@@ -34,7 +38,9 @@ DownloadStateInfo::DownloadStateInfo(
bool prompt_user_for_save_location,
int uniquifier,
bool dangerous_file,
- bool dangerous_url)
+ bool dangerous_url,
+ bool dangerous_content,
+ bool needs_tmp_file)
: target_name(target),
path_uniquifier(uniquifier),
has_user_gesture(has_user_gesture),
@@ -42,9 +48,11 @@ DownloadStateInfo::DownloadStateInfo(
prompt_user_for_save_location(prompt_user_for_save_location),
is_dangerous_file(dangerous_file),
is_dangerous_url(dangerous_url),
+ is_dangerous_content(dangerous_content),
+ needs_quarantine_file(needs_tmp_file),
force_file_name(forced_name) {
}
bool DownloadStateInfo::IsDangerous() const {
- return is_dangerous_url || is_dangerous_file;
+ return is_dangerous_url || is_dangerous_file || is_dangerous_content;
}

Powered by Google App Engine
This is Rietveld 408576698