| Index: net/ssl/ssl_platform_key_android.cc
|
| diff --git a/net/ssl/ssl_platform_key_android.cc b/net/ssl/ssl_platform_key_android.cc
|
| index 773844a08fa01ff2c25e651de0da505d711b5fa9..d4c522ef1b67c79dd4c10ca5950bffb41423fe44 100644
|
| --- a/net/ssl/ssl_platform_key_android.cc
|
| +++ b/net/ssl/ssl_platform_key_android.cc
|
| @@ -13,6 +13,7 @@
|
| #include "crypto/scoped_openssl_types.h"
|
| #include "net/base/net_errors.h"
|
| #include "net/ssl/openssl_client_key_store.h"
|
| +#include "net/ssl/ssl_platform_key_task_runner.h"
|
| #include "net/ssl/ssl_private_key.h"
|
| #include "net/ssl/threaded_ssl_private_key.h"
|
|
|
| @@ -107,12 +108,7 @@ class SSLPlatformKeyAndroid : public ThreadedSSLPrivateKey::Delegate {
|
|
|
| } // namespace
|
|
|
| -scoped_ptr<SSLPrivateKey> FetchClientCertPrivateKey(
|
| - X509Certificate* certificate,
|
| - scoped_refptr<base::SequencedTaskRunner> task_runner) {
|
| - crypto::ScopedEVP_PKEY key =
|
| - OpenSSLClientKeyStore::GetInstance()->FetchClientCertPrivateKey(
|
| - certificate);
|
| +scoped_refptr<SSLPrivateKey> WrapOpenSSLPrivateKey(crypto::ScopedEVP_PKEY key) {
|
| if (!key)
|
| return nullptr;
|
|
|
| @@ -128,9 +124,17 @@ scoped_ptr<SSLPrivateKey> FetchClientCertPrivateKey(
|
| LOG(ERROR) << "Unknown key type: " << EVP_PKEY_id(key.get());
|
| return nullptr;
|
| }
|
| - return make_scoped_ptr(new ThreadedSSLPrivateKey(
|
| + return make_scoped_refptr(new ThreadedSSLPrivateKey(
|
| make_scoped_ptr(new SSLPlatformKeyAndroid(key.Pass(), type)),
|
| - task_runner.Pass()));
|
| + GetSSLPlatformKeyTaskRunner()));
|
| +}
|
| +
|
| +scoped_refptr<SSLPrivateKey> FetchClientCertPrivateKey(
|
| + X509Certificate* certificate) {
|
| + crypto::ScopedEVP_PKEY key =
|
| + OpenSSLClientKeyStore::GetInstance()->FetchClientCertPrivateKey(
|
| + certificate);
|
| + return WrapOpenSSLPrivateKey(key.Pass());
|
| }
|
|
|
| } // namespace net
|
|
|