Mercurial > hg > nginx-quic
comparison src/os/win32/ngx_thread.c @ 6111:537259db5af4
Removed "worker_threads" and "thread_stack_size" directives.
author | Ruslan Ermilov <ru@nginx.com> |
---|---|
date | Thu, 26 Mar 2015 14:15:17 +0300 |
parents | 16c51e80128c |
children |
comparison
equal
deleted
inserted
replaced
6110:16c51e80128c | 6111:537259db5af4 |
---|---|
7 | 7 |
8 #include <ngx_config.h> | 8 #include <ngx_config.h> |
9 #include <ngx_core.h> | 9 #include <ngx_core.h> |
10 | 10 |
11 | 11 |
12 ngx_int_t ngx_threads_n; | |
13 | |
14 | |
15 static size_t stack_size; | |
16 | |
17 | |
18 ngx_err_t | 12 ngx_err_t |
19 ngx_create_thread(ngx_tid_t *tid, | 13 ngx_create_thread(ngx_tid_t *tid, |
20 ngx_thread_value_t (__stdcall *func)(void *arg), void *arg, ngx_log_t *log) | 14 ngx_thread_value_t (__stdcall *func)(void *arg), void *arg, ngx_log_t *log) |
21 { | 15 { |
22 u_long id; | 16 u_long id; |
23 ngx_err_t err; | 17 ngx_err_t err; |
24 | 18 |
25 *tid = CreateThread(NULL, stack_size, func, arg, 0, &id); | 19 *tid = CreateThread(NULL, 0, func, arg, 0, &id); |
26 | 20 |
27 if (*tid != NULL) { | 21 if (*tid != NULL) { |
28 ngx_log_error(NGX_LOG_NOTICE, log, 0, | 22 ngx_log_error(NGX_LOG_NOTICE, log, 0, |
29 "create thread " NGX_TID_T_FMT, id); | 23 "create thread " NGX_TID_T_FMT, id); |
30 return 0; | 24 return 0; |
32 | 26 |
33 err = ngx_errno; | 27 err = ngx_errno; |
34 ngx_log_error(NGX_LOG_ALERT, log, err, "CreateThread() failed"); | 28 ngx_log_error(NGX_LOG_ALERT, log, err, "CreateThread() failed"); |
35 return err; | 29 return err; |
36 } | 30 } |
37 | |
38 | |
39 ngx_int_t | |
40 ngx_init_threads(int n, size_t size, ngx_cycle_t *cycle) | |
41 { | |
42 stack_size = size; | |
43 | |
44 return NGX_OK; | |
45 } |