You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

22 lines
784 B

  1. --- a/tlscommon.c
  2. +++ b/tlscommon.c
  3. @@ -44,8 +44,8 @@ static uint8_t cookie_secret_initialized = 0;
  4. #if OPENSSL_VERSION_NUMBER < 0x10100000
  5. static pthread_mutex_t *ssl_locks = NULL;
  6. -unsigned long ssl_thread_id() {
  7. - return (unsigned long)pthread_self();
  8. +void ssl_thread_id(CRYPTO_THREADID *id) {
  9. + CRYPTO_THREADID_set_numeric(id, (unsigned long)pthread_self());
  10. }
  11. void ssl_locking_callback(int mode, int type, const char *file, int line) {
  12. @@ -69,7 +69,7 @@ void sslinit() {
  13. for (i = 0; i < CRYPTO_num_locks(); i++) {
  14. pthread_mutex_init(&ssl_locks[i], NULL);
  15. }
  16. - CRYPTO_set_id_callback(ssl_thread_id);
  17. + CRYPTO_THREADID_set_callback(ssl_thread_id);
  18. CRYPTO_set_locking_callback(ssl_locking_callback);
  19. SSL_load_error_strings();
  20. #else