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

Unified Diff: chrome/browser/extensions/updater/local_extension_cache_unittest.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
Index: chrome/browser/extensions/updater/local_extension_cache_unittest.cc
diff --git a/chrome/browser/extensions/updater/local_extension_cache_unittest.cc b/chrome/browser/extensions/updater/local_extension_cache_unittest.cc
index efcf267cb2530c2f9f15e6204d501c552b7047bc..1ef40a4b77bef938fa2307d1302386729d4cafb5 100644
--- a/chrome/browser/extensions/updater/local_extension_cache_unittest.cc
+++ b/chrome/browser/extensions/updater/local_extension_cache_unittest.cc
@@ -98,14 +98,13 @@ class LocalExtensionCacheTest : public testing::Test {
base::FilePath* filename) {
std::string data(size, 0);
- crypto::SecureHash* hash =
+ std::unique_ptr<crypto::SecureHash> hash =
crypto::SecureHash::Create(crypto::SecureHash::SHA256);
hash->Update(data.c_str(), size);
uint8_t output[crypto::kSHA256Length];
hash->Finish(output, sizeof(output));
const std::string hex_hash =
base::ToLowerASCII(base::HexEncode(output, sizeof(output)));
- delete hash;
const base::FilePath file =
GetExtensionFileName(dir, id, version, hex_hash);
« no previous file with comments | « chrome/browser/chromeos/settings/token_encryptor.cc ('k') | chrome/browser/net/quota_policy_channel_id_store_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698