Loading crypto/bio/b_addr.c +1 −3 Original line number Diff line number Diff line Loading @@ -19,7 +19,6 @@ #include <ctype.h> CRYPTO_RWLOCK *bio_lookup_lock; extern CRYPTO_RWLOCK *bio_type_lock; static CRYPTO_ONCE bio_lookup_init = CRYPTO_ONCE_STATIC_INIT; /* Loading Loading @@ -606,8 +605,7 @@ static int addrinfo_wrap(int family, int socktype, DEFINE_RUN_ONCE_STATIC(do_bio_lookup_init) { bio_lookup_lock = CRYPTO_THREAD_lock_new(); bio_type_lock = CRYPTO_THREAD_lock_new(); return bio_lookup_lock != NULL && bio_type_lock != NULL; return bio_lookup_lock != NULL; } /*- Loading crypto/bio/bio_err.c +1 −0 Original line number Diff line number Diff line Loading @@ -29,6 +29,7 @@ static ERR_STRING_DATA BIO_str_functs[] = { {ERR_FUNC(BIO_F_BIO_CTRL), "BIO_ctrl"}, {ERR_FUNC(BIO_F_BIO_GETS), "BIO_gets"}, {ERR_FUNC(BIO_F_BIO_GET_HOST_IP), "BIO_get_host_ip"}, {ERR_FUNC(BIO_F_BIO_GET_NEW_INDEX), "BIO_get_new_index"}, {ERR_FUNC(BIO_F_BIO_GET_PORT), "BIO_get_port"}, {ERR_FUNC(BIO_F_BIO_LISTEN), "BIO_listen"}, {ERR_FUNC(BIO_F_BIO_LOOKUP), "BIO_lookup"}, Loading crypto/bio/bio_lib.c +1 −1 Original line number Diff line number Diff line Loading @@ -594,7 +594,7 @@ void bio_cleanup(void) bio_sock_cleanup_int(); CRYPTO_THREAD_lock_free(bio_lookup_lock); bio_lookup_lock = NULL; #endif CRYPTO_THREAD_lock_free(bio_type_lock); bio_type_lock = NULL; #endif } crypto/bio/bio_meth.c +14 −2 Original line number Diff line number Diff line Loading @@ -8,14 +8,26 @@ */ #include "bio_lcl.h" #include <internal/thread_once.h> CRYPTO_RWLOCK *bio_type_lock; static int bio_count = BIO_TYPE_START; CRYPTO_RWLOCK *bio_type_lock = NULL; static CRYPTO_ONCE bio_type_init = CRYPTO_ONCE_STATIC_INIT; DEFINE_RUN_ONCE_STATIC(do_bio_type_init) { bio_type_lock = CRYPTO_THREAD_lock_new(); return bio_type_lock != NULL; } int BIO_get_new_index() { static int bio_count = BIO_TYPE_START; int newval; if (!RUN_ONCE(&bio_type_init, do_bio_type_init)) { BIOerr(BIO_F_BIO_GET_NEW_INDEX, ERR_R_MALLOC_FAILURE); return -1; } if (!CRYPTO_atomic_add(&bio_count, 1, &newval, bio_type_lock)) return -1; return newval; Loading include/openssl/bio.h +1 −0 Original line number Diff line number Diff line Loading @@ -779,6 +779,7 @@ int ERR_load_BIO_strings(void); # define BIO_F_BIO_CTRL 103 # define BIO_F_BIO_GETS 104 # define BIO_F_BIO_GET_HOST_IP 106 # define BIO_F_BIO_GET_NEW_INDEX 102 # define BIO_F_BIO_GET_PORT 107 # define BIO_F_BIO_LISTEN 139 # define BIO_F_BIO_LOOKUP 135 Loading Loading
crypto/bio/b_addr.c +1 −3 Original line number Diff line number Diff line Loading @@ -19,7 +19,6 @@ #include <ctype.h> CRYPTO_RWLOCK *bio_lookup_lock; extern CRYPTO_RWLOCK *bio_type_lock; static CRYPTO_ONCE bio_lookup_init = CRYPTO_ONCE_STATIC_INIT; /* Loading Loading @@ -606,8 +605,7 @@ static int addrinfo_wrap(int family, int socktype, DEFINE_RUN_ONCE_STATIC(do_bio_lookup_init) { bio_lookup_lock = CRYPTO_THREAD_lock_new(); bio_type_lock = CRYPTO_THREAD_lock_new(); return bio_lookup_lock != NULL && bio_type_lock != NULL; return bio_lookup_lock != NULL; } /*- Loading
crypto/bio/bio_err.c +1 −0 Original line number Diff line number Diff line Loading @@ -29,6 +29,7 @@ static ERR_STRING_DATA BIO_str_functs[] = { {ERR_FUNC(BIO_F_BIO_CTRL), "BIO_ctrl"}, {ERR_FUNC(BIO_F_BIO_GETS), "BIO_gets"}, {ERR_FUNC(BIO_F_BIO_GET_HOST_IP), "BIO_get_host_ip"}, {ERR_FUNC(BIO_F_BIO_GET_NEW_INDEX), "BIO_get_new_index"}, {ERR_FUNC(BIO_F_BIO_GET_PORT), "BIO_get_port"}, {ERR_FUNC(BIO_F_BIO_LISTEN), "BIO_listen"}, {ERR_FUNC(BIO_F_BIO_LOOKUP), "BIO_lookup"}, Loading
crypto/bio/bio_lib.c +1 −1 Original line number Diff line number Diff line Loading @@ -594,7 +594,7 @@ void bio_cleanup(void) bio_sock_cleanup_int(); CRYPTO_THREAD_lock_free(bio_lookup_lock); bio_lookup_lock = NULL; #endif CRYPTO_THREAD_lock_free(bio_type_lock); bio_type_lock = NULL; #endif }
crypto/bio/bio_meth.c +14 −2 Original line number Diff line number Diff line Loading @@ -8,14 +8,26 @@ */ #include "bio_lcl.h" #include <internal/thread_once.h> CRYPTO_RWLOCK *bio_type_lock; static int bio_count = BIO_TYPE_START; CRYPTO_RWLOCK *bio_type_lock = NULL; static CRYPTO_ONCE bio_type_init = CRYPTO_ONCE_STATIC_INIT; DEFINE_RUN_ONCE_STATIC(do_bio_type_init) { bio_type_lock = CRYPTO_THREAD_lock_new(); return bio_type_lock != NULL; } int BIO_get_new_index() { static int bio_count = BIO_TYPE_START; int newval; if (!RUN_ONCE(&bio_type_init, do_bio_type_init)) { BIOerr(BIO_F_BIO_GET_NEW_INDEX, ERR_R_MALLOC_FAILURE); return -1; } if (!CRYPTO_atomic_add(&bio_count, 1, &newval, bio_type_lock)) return -1; return newval; Loading
include/openssl/bio.h +1 −0 Original line number Diff line number Diff line Loading @@ -779,6 +779,7 @@ int ERR_load_BIO_strings(void); # define BIO_F_BIO_CTRL 103 # define BIO_F_BIO_GETS 104 # define BIO_F_BIO_GET_HOST_IP 106 # define BIO_F_BIO_GET_NEW_INDEX 102 # define BIO_F_BIO_GET_PORT 107 # define BIO_F_BIO_LISTEN 139 # define BIO_F_BIO_LOOKUP 135 Loading