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

Unified Diff: content/browser/ssl/ssl_client_auth_handler.cc

Issue 873723003: Follow-up changes to https://codereview.chromium.org/795773002/ (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: More compile fix Created 5 years, 11 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: content/browser/ssl/ssl_client_auth_handler.cc
diff --git a/content/browser/ssl/ssl_client_auth_handler.cc b/content/browser/ssl/ssl_client_auth_handler.cc
index fe2fac9012a1b66ea11a0f5ff49e2d5e0d4d6fc3..db961cf0d38ae302573e27d5ac146a043e0a1466 100644
--- a/content/browser/ssl/ssl_client_auth_handler.cc
+++ b/content/browser/ssl/ssl_client_auth_handler.cc
@@ -56,6 +56,10 @@ class SSLClientAuthHandler::Core : public base::RefCountedThreadSafe<Core> {
void GetClientCerts() {
if (client_cert_store_) {
+ // TODO(davidben): This is still a cyclical ownership where
+ // GetClientCerts' requirement that |client_cert_store_| remains alive
+ // until the call completes is maintained by the reference held in the
+ // callback.
client_cert_store_->GetClientCerts(
*cert_request_info_, &cert_request_info_->client_certs,
base::Bind(&SSLClientAuthHandler::Core::DidGetClientCerts, this));
@@ -85,8 +89,7 @@ SSLClientAuthHandler::SSLClientAuthHandler(
net::URLRequest* request,
net::SSLCertRequestInfo* cert_request_info,
const SSLClientAuthHandler::CertificateCallback& callback)
- : core_(nullptr),
- request_(request),
+ : request_(request),
cert_request_info_(cert_request_info),
callback_(callback),
weak_factory_(this) {
@@ -142,7 +145,6 @@ void SSLClientAuthHandler::CertificateSelected(net::X509Certificate* cert) {
DCHECK_CURRENTLY_ON(BrowserThread::IO);
callback_.Run(cert);
- // |this| may be deleted at this point.
}
} // namespace content

Powered by Google App Engine
This is Rietveld 408576698