Skip to content
This repository has been archived by the owner on Jun 30, 2021. It is now read-only.

Commit

Permalink
[#122] cleanup for ssl locking changes
Browse files Browse the repository at this point in the history
  • Loading branch information
NathanFrench committed Jan 24, 2019
1 parent 8e543fe commit 7d0fd5d
Showing 1 changed file with 7 additions and 9 deletions.
16 changes: 7 additions & 9 deletions evhtp.c
Original file line number Diff line number Diff line change
Expand Up @@ -2827,27 +2827,27 @@ htp__accept_cb_(struct evconnlistener * serv, int fd, struct sockaddr * s, int s

#ifndef EVHTP_DISABLE_SSL
#ifndef EVHTP_DISABLE_EVTHR
#if OPENSSL_VERSION_NUMBER < 0x10100000L

#ifndef WIN32
#define tid (unsigned long)pthread_self()
#define _HTP_tid (unsigned long)pthread_self()
#else
#define tid pthread_self().p
#define _HTP_tid pthread_self().p
#endif

#if OPENSSL_VERSION_NUMBER < 0x10000000L
static unsigned long
htp__ssl_get_thread_id_(void)
{
return tid;
return _HTP_tid;
}

#else

static void
htp__ssl_get_thread_id_(CRYPTO_THREADID *id)
htp__ssl_get_thread_id_(CRYPTO_THREADID * id)
{
CRYPTO_THREADID_set_numeric(id, tid);
CRYPTO_THREADID_set_numeric(id, _HTP_tid);
}
#endif

#endif

Expand Down Expand Up @@ -4687,7 +4687,6 @@ evhtp_set_post_accept_cb(evhtp_t * htp, evhtp_post_accept_cb cb, void * arg)

#ifndef EVHTP_DISABLE_SSL
#ifndef EVHTP_DISABLE_EVTHR
#if OPENSSL_VERSION_NUMBER < 0x10100000L
int
evhtp_ssl_use_threads(void)
{
Expand Down Expand Up @@ -4720,7 +4719,6 @@ evhtp_ssl_use_threads(void)
return 0;
}

#endif
#endif

int
Expand Down

0 comments on commit 7d0fd5d

Please sign in to comment.