OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "content/browser/download/download_net_log_parameters.h" | 5 #include "content/browser/download/download_net_log_parameters.h" |
6 | 6 |
7 #include "base/basictypes.h" | 7 #include "base/basictypes.h" |
8 #include "base/file_path.h" | 8 #include "base/file_path.h" |
9 #include "base/logging.h" | 9 #include "base/logging.h" |
10 #include "base/string_number_conversions.h" | 10 #include "base/string_number_conversions.h" |
(...skipping 11 matching lines...) Expand all Loading... |
22 "HISTORY_IMPORT", | 22 "HISTORY_IMPORT", |
23 "SAVE_PAGE_AS" | 23 "SAVE_PAGE_AS" |
24 }; | 24 }; |
25 static const char* download_danger_names[] = { | 25 static const char* download_danger_names[] = { |
26 "NOT_DANGEROUS", | 26 "NOT_DANGEROUS", |
27 "DANGEROUS_FILE", | 27 "DANGEROUS_FILE", |
28 "DANGEROUS_URL", | 28 "DANGEROUS_URL", |
29 "DANGEROUS_CONTENT", | 29 "DANGEROUS_CONTENT", |
30 "MAYBE_DANGEROUS_CONTENT", | 30 "MAYBE_DANGEROUS_CONTENT", |
31 "UNCOMMON_CONTENT", | 31 "UNCOMMON_CONTENT", |
32 "USER_VALIDATED" | 32 "USER_VALIDATED", |
| 33 "DANGEROUS_HOST", |
33 }; | 34 }; |
34 | 35 |
35 COMPILE_ASSERT(ARRAYSIZE_UNSAFE(download_type_names) == SRC_SAVE_PAGE_AS + 1, | 36 COMPILE_ASSERT(ARRAYSIZE_UNSAFE(download_type_names) == SRC_SAVE_PAGE_AS + 1, |
36 download_type_enum_has_changed); | 37 download_type_enum_has_changed); |
37 COMPILE_ASSERT(ARRAYSIZE_UNSAFE(download_danger_names) == | 38 COMPILE_ASSERT(ARRAYSIZE_UNSAFE(download_danger_names) == |
38 DOWNLOAD_DANGER_TYPE_MAX, | 39 DOWNLOAD_DANGER_TYPE_MAX, |
39 download_danger_enum_has_changed); | 40 download_danger_enum_has_changed); |
40 | 41 |
41 } // namespace | 42 } // namespace |
42 | 43 |
(...skipping 155 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
198 dict->SetString("operation", operation); | 199 dict->SetString("operation", operation); |
199 if (os_error != 0) | 200 if (os_error != 0) |
200 dict->SetInteger("os_error", os_error); | 201 dict->SetInteger("os_error", os_error); |
201 dict->SetString("interrupt_reason", InterruptReasonDebugString(reason)); | 202 dict->SetString("interrupt_reason", InterruptReasonDebugString(reason)); |
202 | 203 |
203 return dict; | 204 return dict; |
204 } | 205 } |
205 | 206 |
206 | 207 |
207 } // namespace content | 208 } // namespace content |
OLD | NEW |