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

Unified Diff: crypto/hkdf.cc

Issue 1870233002: Convert crypto to std::unique_ptr (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: comment Created 4 years, 8 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 | « crypto/encryptor_unittest.cc ('k') | crypto/hmac.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: crypto/hkdf.cc
diff --git a/crypto/hkdf.cc b/crypto/hkdf.cc
index 67c39216b9653e535c7176a2eb9cc9faa6c22649..2483e6029bc0454fcf6fe3aead6e3aaa83bb13b4 100644
--- a/crypto/hkdf.cc
+++ b/crypto/hkdf.cc
@@ -7,8 +7,9 @@
#include <stddef.h>
#include <stdint.h>
+#include <memory>
+
#include "base/logging.h"
-#include "base/memory/scoped_ptr.h"
#include "crypto/hmac.h"
namespace crypto {
@@ -55,7 +56,7 @@ HKDF::HKDF(const base::StringPiece& secret,
output_.resize(n * kSHA256HashLength);
base::StringPiece previous;
- scoped_ptr<char[]> buf(new char[kSHA256HashLength + info.size() + 1]);
+ std::unique_ptr<char[]> buf(new char[kSHA256HashLength + info.size() + 1]);
uint8_t digest[kSHA256HashLength];
HMAC hmac(HMAC::SHA256);
« no previous file with comments | « crypto/encryptor_unittest.cc ('k') | crypto/hmac.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698