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

Unified Diff: components/crx_file/crx_file.cc

Issue 2095523002: Make //crypto factories return std::unique_ptr<>s (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: I'm blind Created 4 years, 6 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 | « chrome/browser/net/quota_policy_channel_id_store_unittest.cc ('k') | components/os_crypt/os_crypt_mac.mm » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: components/crx_file/crx_file.cc
diff --git a/components/crx_file/crx_file.cc b/components/crx_file/crx_file.cc
index 7a310aca98828693d9b2bc4e235fbb76b7b7b36f..2445ef1e6629bf5c439bfe0551acddde6d53ce60 100644
--- a/components/crx_file/crx_file.cc
+++ b/components/crx_file/crx_file.cc
@@ -111,7 +111,7 @@ CrxFile::ValidateError CrxFile::ValidateSignature(
base::ScopedFILE file(base::OpenFile(crx_path, "rb"));
std::unique_ptr<crypto::SecureHash> hash;
if (!expected_hash.empty())
- hash.reset(crypto::SecureHash::Create(crypto::SecureHash::SHA256));
+ hash = crypto::SecureHash::Create(crypto::SecureHash::SHA256);
if (!file.get())
return ValidateError::CRX_FILE_NOT_READABLE;
« no previous file with comments | « chrome/browser/net/quota_policy_channel_id_store_unittest.cc ('k') | components/os_crypt/os_crypt_mac.mm » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698