diff options
author | Kazuki Yamaguchi <k@rhe.jp> | 2016-04-20 18:02:58 +0900 |
---|---|---|
committer | Kazuki Yamaguchi <k@rhe.jp> | 2016-04-27 23:07:41 +0900 |
commit | 1cf43c17514c79b28571d649387c17e4e3dd2810 (patch) | |
tree | f90dfe260b2a33a3ee5434f1a22296e5331d92c3 /ext/openssl/ossl_pkey.c | |
parent | 91661b39556bc814e47a53d870ec3eb00f1e1942 (diff) | |
download | ruby-1cf43c17514c79b28571d649387c17e4e3dd2810.tar.gz |
ext/openssl: use *_up_ref() functions
Diffstat (limited to 'ext/openssl/ossl_pkey.c')
-rw-r--r-- | ext/openssl/ossl_pkey.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/ext/openssl/ossl_pkey.c b/ext/openssl/ossl_pkey.c index 4990ce8e08..4bf36a6ecc 100644 --- a/ext/openssl/ossl_pkey.c +++ b/ext/openssl/ossl_pkey.c @@ -197,7 +197,7 @@ DupPKeyPtr(VALUE obj) EVP_PKEY *pkey; SafeGetPKey(obj, pkey); - CRYPTO_add(&pkey->references, 1, CRYPTO_LOCK_EVP_PKEY); + EVP_PKEY_up_ref(pkey); return pkey; } @@ -211,7 +211,7 @@ DupPrivPKeyPtr(VALUE obj) ossl_raise(rb_eArgError, "Private key is needed."); } SafeGetPKey(obj, pkey); - CRYPTO_add(&pkey->references, 1, CRYPTO_LOCK_EVP_PKEY); + EVP_PKEY_up_ref(pkey); return pkey; } |