mirror of
https://github.com/3proxy/3proxy.git
synced 2025-02-24 02:55:40 +08:00
Fix thread init bug introduced
This commit is contained in:
parent
b40e8fae4c
commit
ad9b0046d9
@ -61,7 +61,7 @@ struct extparam conf = {
|
||||
#ifdef __FreeBSD__
|
||||
16384,
|
||||
#else
|
||||
0
|
||||
0,
|
||||
#endif
|
||||
0, -1, 0, 0, 0, 0, 0, 500, 0, 0, 0,
|
||||
6, 600,
|
||||
|
@ -401,9 +401,6 @@ int MODULEMAINFUNC (int argc, char** argv){
|
||||
return((*srv.pf)((void *)newparam)? 1:0);
|
||||
|
||||
}
|
||||
pthread_attr_init(&pa);
|
||||
pthread_attr_setstacksize(&pa,PTHREAD_STACK_MIN + (8192 + srv.stacksize));
|
||||
pthread_attr_setdetachstate(&pa,PTHREAD_CREATE_DETACHED);
|
||||
#endif
|
||||
|
||||
|
||||
@ -509,6 +506,11 @@ int MODULEMAINFUNC (int argc, char** argv){
|
||||
srv.fds.fd = sock;
|
||||
srv.fds.events = POLLIN;
|
||||
|
||||
#ifndef _WIN32
|
||||
pthread_attr_init(&pa);
|
||||
pthread_attr_setstacksize(&pa,PTHREAD_STACK_MIN + (8192 + srv.stacksize));
|
||||
pthread_attr_setdetachstate(&pa,PTHREAD_CREATE_DETACHED);
|
||||
#endif
|
||||
|
||||
for (;;) {
|
||||
for(;;){
|
||||
|
Loading…
Reference in New Issue
Block a user