Index: crypto/ec_private_key_openssl.cc |
diff --git a/crypto/ec_private_key_openssl.cc b/crypto/ec_private_key_openssl.cc |
index 45657a73911cdd4ff37fe192fe8251a31bdd368e..35403f39ce88588a492f222800842268ce55ddd4 100644 |
--- a/crypto/ec_private_key_openssl.cc |
+++ b/crypto/ec_private_key_openssl.cc |
@@ -88,7 +88,7 @@ ECPrivateKey::~ECPrivateKey() { |
ECPrivateKey* ECPrivateKey::Copy() const { |
scoped_ptr<ECPrivateKey> copy(new ECPrivateKey); |
if (key_) |
- copy->key_ = EVP_PKEY_dup(key_); |
+ copy->key_ = EVP_PKEY_up_ref(key_); |
return copy.release(); |
} |