diff options
author | Igor Sysoev <igor@sysoev.ru> | 2004-07-06 16:12:16 +0000 |
---|---|---|
committer | Igor Sysoev <igor@sysoev.ru> | 2004-07-06 16:12:16 +0000 |
commit | 81a432a185bc61d46a4d5eb1f96773ee7b3dc6a3 (patch) | |
tree | 2fc767b2b984c999342761308464c701c6d09457 /src/os/unix/ngx_thread.h | |
parent | 40e877165a22f19359344d897c68da4fce62f6c1 (diff) | |
download | nginx-81a432a185bc61d46a4d5eb1f96773ee7b3dc6a3.tar.gz nginx-81a432a185bc61d46a4d5eb1f96773ee7b3dc6a3.zip |
nginx-0.0.7-2004-07-06-20:12:16 import
Diffstat (limited to 'src/os/unix/ngx_thread.h')
-rw-r--r-- | src/os/unix/ngx_thread.h | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/src/os/unix/ngx_thread.h b/src/os/unix/ngx_thread.h index 3bd9753d7..e30a148dd 100644 --- a/src/os/unix/ngx_thread.h +++ b/src/os/unix/ngx_thread.h @@ -27,6 +27,12 @@ typedef pthread_t ngx_tid_t; #define TID_T_FMT PTR_FMT +#define ngx_thread_create_tls() pthread_key_create(0, NULL) +#define ngx_thread_create_tls_n "pthread_key_create(0, NULL)" +#define ngx_thread_get_tls() pthread_getspecific(0) +#define ngx_thread_set_tls(v) pthread_setspecific(0, v) + + #define NGX_MUTEX_LIGHT 0 typedef struct { @@ -106,4 +112,10 @@ ngx_int_t ngx_cond_signal(ngx_cond_t *cv); #endif +typedef struct { + ngx_event_t *event; +} ngx_tls_t; + + + #endif /* _NGX_THREAD_H_INCLUDED_ */ |