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

Unified Diff: components/cast_certificate/cast_cert_validator.cc

Issue 2257793002: Re-write many calls to WrapUnique() with MakeUnique() (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase Created 4 years, 4 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
« no previous file with comments | « components/browsing_data/core/counters/history_counter.cc ('k') | components/cast_certificate/cast_crl.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: components/cast_certificate/cast_cert_validator.cc
diff --git a/components/cast_certificate/cast_cert_validator.cc b/components/cast_certificate/cast_cert_validator.cc
index e08eae7fb8ff6fcbe020113ff3731c8e9b5b1cfe..c1c34389f667653e081bfaa8800517a3ca5ba64b 100644
--- a/components/cast_certificate/cast_cert_validator.cc
+++ b/components/cast_certificate/cast_cert_validator.cc
@@ -116,7 +116,7 @@ net::der::Input AudioOnlyPolicyOid() {
// * Hashes: All SHA hashes including SHA-1 (despite being known weak).
// * RSA keys must have a modulus at least 2048-bits long.
std::unique_ptr<net::SignaturePolicy> CreateCastSignaturePolicy() {
- return base::WrapUnique(new net::SimpleSignaturePolicy(2048));
+ return base::MakeUnique<net::SimpleSignaturePolicy>(2048);
}
class CertVerificationContextImpl : public CertVerificationContext {
@@ -352,8 +352,8 @@ std::unique_ptr<CertVerificationContext> CertVerificationContextImplForTest(
const base::StringPiece& spki) {
// Use a bogus CommonName, since this is just exposed for testing signature
// verification by unittests.
- return base::WrapUnique(
- new CertVerificationContextImpl(net::der::Input(spki), "CommonName"));
+ return base::MakeUnique<CertVerificationContextImpl>(net::der::Input(spki),
+ "CommonName");
}
} // namespace cast_certificate
« no previous file with comments | « components/browsing_data/core/counters/history_counter.cc ('k') | components/cast_certificate/cast_crl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698