summaryrefslogtreecommitdiffstats
path: root/Source
diff options
context:
space:
mode:
authorSelim Gurun <sgurun@google.com>2012-06-07 10:10:38 -0700
committerSelim Gurun <sgurun@google.com>2012-06-07 10:58:11 -0700
commit6c9f55f6f57bd4da36053c76a1cfce8a15a00a97 (patch)
tree14831d305d252c4e8394b8c60d09481c2e898720 /Source
parent694d4b356b21c9d78cf5ba3ce101b0a76a23f859 (diff)
downloadexternal_webkit-6c9f55f6f57bd4da36053c76a1cfce8a15a00a97.zip
external_webkit-6c9f55f6f57bd4da36053c76a1cfce8a15a00a97.tar.gz
external_webkit-6c9f55f6f57bd4da36053c76a1cfce8a15a00a97.tar.bz2
Use scoped_refptr's rather than naked ptrs.
Bug: 6508448 This is to make sure webkit usage of scoped refptrs are compatible with chromium changes, see bug for more details. Change-Id: I24e3615ba961ba928d1074d54ea0bfe2d051519a
Diffstat (limited to 'Source')
-rw-r--r--Source/WebKit/android/jni/WebCoreFrameBridge.cpp10
1 files changed, 5 insertions, 5 deletions
diff --git a/Source/WebKit/android/jni/WebCoreFrameBridge.cpp b/Source/WebKit/android/jni/WebCoreFrameBridge.cpp
index c03c288..4cd39f6 100644
--- a/Source/WebKit/android/jni/WebCoreFrameBridge.cpp
+++ b/Source/WebKit/android/jni/WebCoreFrameBridge.cpp
@@ -1822,7 +1822,7 @@ static void SslCertErrorCancel(JNIEnv *env, jobject obj, int handle, int cert_er
client->cancelSslCertError(cert_error);
}
-static net::X509Certificate* getX509Cert(JNIEnv *env, jobjectArray chain)
+static scoped_refptr<net::X509Certificate> getX509Cert(JNIEnv *env, jobjectArray chain)
{
// Based on Android's NativeCrypto_SSL_use_certificate
int length = env->GetArrayLength(chain);
@@ -1860,8 +1860,8 @@ static net::X509Certificate* getX509Cert(JNIEnv *env, jobjectArray chain)
certChain[i] = rest[i]->get();
}
return net::X509Certificate::CreateFromHandle(first.get(),
- net::X509Certificate::SOURCE_FROM_NETWORK,
- certChain);
+ net::X509Certificate::SOURCE_FROM_NETWORK,
+ certChain);
}
static void SslClientCertPKCS8(JNIEnv *env, jobject obj, int handle, jbyteArray pkey, jobjectArray chain)
@@ -1891,7 +1891,7 @@ static void SslClientCertPKCS8(JNIEnv *env, jobject obj, int handle, jbyteArray
client->sslClientCert(NULL, NULL);
return;
}
- net::X509Certificate* certificate = getX509Cert(env, chain);
+ scoped_refptr<net::X509Certificate> certificate = getX509Cert(env, chain);
if (certificate == NULL) {
client->sslClientCert(NULL, NULL);
return;
@@ -1907,7 +1907,7 @@ static void SslClientCertCtx(JNIEnv *env, jobject obj, int handle, jint ctx, job
client->sslClientCert(NULL, NULL);
return;
}
- net::X509Certificate* certificate = getX509Cert(env, chain);
+ scoped_refptr<net::X509Certificate> certificate = getX509Cert(env, chain);
if (certificate == NULL) {
client->sslClientCert(NULL, NULL);
return;