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

Side by Side Diff: chrome/browser/ssl/certificate_error_report.cc

Issue 1223153003: Move JoinString to the base namespace (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: windows Created 5 years, 5 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 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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/ssl/certificate_error_report.h" 5 #include "chrome/browser/ssl/certificate_error_report.h"
6 6
7 #include <vector> 7 #include <vector>
8 8
9 #include "base/stl_util.h" 9 #include "base/stl_util.h"
10 #include "base/strings/string_util.h" 10 #include "base/strings/string_util.h"
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after
49 if (cert_status & net::CERT_STATUS_NO_REVOCATION_MECHANISM) 49 if (cert_status & net::CERT_STATUS_NO_REVOCATION_MECHANISM)
50 report->add_cert_error(CertLoggerRequest::ERR_CERT_NO_REVOCATION_MECHANISM); 50 report->add_cert_error(CertLoggerRequest::ERR_CERT_NO_REVOCATION_MECHANISM);
51 } 51 }
52 52
53 bool CertificateChainToString(scoped_refptr<net::X509Certificate> cert, 53 bool CertificateChainToString(scoped_refptr<net::X509Certificate> cert,
54 std::string* result) { 54 std::string* result) {
55 std::vector<std::string> pem_encoded_chain; 55 std::vector<std::string> pem_encoded_chain;
56 if (!cert->GetPEMEncodedChain(&pem_encoded_chain)) 56 if (!cert->GetPEMEncodedChain(&pem_encoded_chain))
57 return false; 57 return false;
58 58
59 *result = JoinString(pem_encoded_chain, std::string()); 59 *result = base::JoinString(pem_encoded_chain, base::StringPiece());
60 return true; 60 return true;
61 } 61 }
62 62
63 } // namespace 63 } // namespace
64 64
65 CertificateErrorReport::CertificateErrorReport() 65 CertificateErrorReport::CertificateErrorReport()
66 : cert_report_(new CertLoggerRequest()) { 66 : cert_report_(new CertLoggerRequest()) {
67 } 67 }
68 68
69 CertificateErrorReport::CertificateErrorReport(const std::string& hostname, 69 CertificateErrorReport::CertificateErrorReport(const std::string& hostname,
(...skipping 54 matching lines...) Expand 10 before | Expand all | Expand 10 after
124 break; 124 break;
125 } 125 }
126 126
127 interstitial_info->set_user_proceeded(proceed_decision == USER_PROCEEDED); 127 interstitial_info->set_user_proceeded(proceed_decision == USER_PROCEEDED);
128 interstitial_info->set_overridable(overridable == INTERSTITIAL_OVERRIDABLE); 128 interstitial_info->set_overridable(overridable == INTERSTITIAL_OVERRIDABLE);
129 } 129 }
130 130
131 const std::string& CertificateErrorReport::hostname() const { 131 const std::string& CertificateErrorReport::hostname() const {
132 return cert_report_->hostname(); 132 return cert_report_->hostname();
133 } 133 }
OLDNEW
« no previous file with comments | « chrome/browser/search/suggestions/suggestions_source.cc ('k') | chrome/browser/ssl/ssl_blocking_page.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698