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

Unified Diff: net/ssl/ssl_client_session_cache.cc

Issue 2400033005: Use BoringSSL scopers in //net. (Closed)
Patch Set: eroman comments Created 4 years, 2 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 | « net/ssl/ssl_client_session_cache.h ('k') | net/ssl/ssl_client_session_cache_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/ssl/ssl_client_session_cache.cc
diff --git a/net/ssl/ssl_client_session_cache.cc b/net/ssl/ssl_client_session_cache.cc
index f1aa1d0e612a4a25fa3394acbe4b13fdefc473da..ccc13ff38f5a1d4bbddb7423a877c2078badd199 100644
--- a/net/ssl/ssl_client_session_cache.cc
+++ b/net/ssl/ssl_client_session_cache.cc
@@ -4,6 +4,8 @@
#include "net/ssl/ssl_client_session_cache.h"
+#include <openssl/ssl.h>
+
#include <utility>
#include "base/memory/memory_coordinator_client_registry.h"
@@ -31,7 +33,8 @@ size_t SSLClientSessionCache::size() const {
return cache_.size();
}
-ScopedSSL_SESSION SSLClientSessionCache::Lookup(const std::string& cache_key) {
+bssl::UniquePtr<SSL_SESSION> SSLClientSessionCache::Lookup(
+ const std::string& cache_key) {
base::AutoLock lock(lock_);
// Expire stale sessions.
@@ -51,7 +54,7 @@ ScopedSSL_SESSION SSLClientSessionCache::Lookup(const std::string& cache_key) {
SSL_SESSION* session = iter->second->session.get();
SSL_SESSION_up_ref(session);
- return ScopedSSL_SESSION(session);
+ return bssl::UniquePtr<SSL_SESSION>(session);
}
void SSLClientSessionCache::Insert(const std::string& cache_key,
« no previous file with comments | « net/ssl/ssl_client_session_cache.h ('k') | net/ssl/ssl_client_session_cache_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698