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

Side by Side Diff: chrome/browser/safe_browsing/protocol_manager_helper.cc

Issue 1402783005: Remove safe_browsing=2 functionality, replace with =3 mode. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: fix up histograms Created 5 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 unified diff | Download patch
OLDNEW
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 "chrome/browser/safe_browsing/protocol_manager_helper.h" 5 #include "chrome/browser/safe_browsing/protocol_manager_helper.h"
6 6
7 #ifndef NDEBUG 7 #ifndef NDEBUG
8 #include "base/base64.h" 8 #include "base/base64.h"
9 #endif 9 #endif
10 #include "base/environment.h" 10 #include "base/environment.h"
11 #include "base/logging.h" 11 #include "base/logging.h"
12 #include "base/stl_util.h" 12 #include "base/stl_util.h"
13 #include "base/strings/string_util.h" 13 #include "base/strings/string_util.h"
14 #include "base/strings/stringprintf.h" 14 #include "base/strings/stringprintf.h"
15 #include "components/version_info/version_info.h" 15 #include "components/version_info/version_info.h"
16 #include "google_apis/google_api_keys.h" 16 #include "google_apis/google_api_keys.h"
17 #include "net/base/escape.h" 17 #include "net/base/escape.h"
18 18
19 SafeBrowsingProtocolConfig::SafeBrowsingProtocolConfig() 19 SafeBrowsingProtocolConfig::SafeBrowsingProtocolConfig()
20 : disable_auto_update(false) 20 : disable_auto_update(false) {}
21 #if defined(OS_ANDROID)
22 , disable_connection_check(false)
23 #endif
24 {
25 }
26 21
27 SafeBrowsingProtocolConfig::~SafeBrowsingProtocolConfig() { 22 SafeBrowsingProtocolConfig::~SafeBrowsingProtocolConfig() {}
28 }
29 23
30 // static 24 // static
31 std::string SafeBrowsingProtocolManagerHelper::Version() { 25 std::string SafeBrowsingProtocolManagerHelper::Version() {
32 if (version_info::GetVersionNumber().empty()) 26 if (version_info::GetVersionNumber().empty())
33 return "0.1"; 27 return "0.1";
34 else 28 else
35 return version_info::GetVersionNumber(); 29 return version_info::GetVersionNumber();
36 } 30 }
37 31
38 // static 32 // static
(...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after
70 bool is_extended_reporting) { 64 bool is_extended_reporting) {
71 std::string url = 65 std::string url =
72 ComposeUrl(prefix, method, client_name, version, additional_query); 66 ComposeUrl(prefix, method, client_name, version, additional_query);
73 if (is_extended_reporting) { 67 if (is_extended_reporting) {
74 url.append("&ext=1"); 68 url.append("&ext=1");
75 } else { 69 } else {
76 url.append("&ext=0"); 70 url.append("&ext=0");
77 } 71 }
78 return url; 72 return url;
79 } 73 }
OLDNEW
« no previous file with comments | « chrome/browser/safe_browsing/protocol_manager_helper.h ('k') | chrome/browser/safe_browsing/protocol_manager_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698