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/openssl_missing.h | |
parent | 91661b39556bc814e47a53d870ec3eb00f1e1942 (diff) | |
download | ruby-1cf43c17514c79b28571d649387c17e4e3dd2810.tar.gz |
ext/openssl: use *_up_ref() functions
Diffstat (limited to 'ext/openssl/openssl_missing.h')
-rw-r--r-- | ext/openssl/openssl_missing.h | 25 |
1 files changed, 25 insertions, 0 deletions
diff --git a/ext/openssl/openssl_missing.h b/ext/openssl/openssl_missing.h index 1e4b2aef93..eab3ca65ef 100644 --- a/ext/openssl/openssl_missing.h +++ b/ext/openssl/openssl_missing.h @@ -85,6 +85,31 @@ int X509_STORE_set_ex_data(X509_STORE *str, int idx, void *data); # define OCSP_SINGLERESP_get0_id(s) ((s)->certId) #endif +#if !defined(HAVE_X509_UP_REF) +# define X509_up_ref(x) \ + CRYPTO_add(&(x)->references, 1, CRYPTO_LOCK_X509) +#endif + +#if !defined(HAVE_X509_CRL_UP_REF) +# define X509_CRL_up_ref(x) \ + CRYPTO_add(&(x)->references, 1, CRYPTO_LOCK_X509_CRL); +#endif + +#if !defined(HAVE_X509_STORE_UP_REF) +# define X509_STORE_up_ref(x) \ + CRYPTO_add(&(x)->references, 1, CRYPTO_LOCK_X509_STORE); +#endif + +#if !defined(HAVE_SSL_SESSION_UP_REF) +# define SSL_SESSION_up_ref(x) \ + CRYPTO_add(&(x)->references, 1, CRYPTO_LOCK_SSL_SESSION); +#endif + +#if !defined(HAVE_EVP_PKEY_UP_REF) +# define EVP_PKEY_up_ref(x) \ + CRYPTO_add(&(x)->references, 1, CRYPTO_LOCK_EVP_PKEY); +#endif + #if defined(__cplusplus) } #endif |