- process_count was wrong when tcp was disabled
authorAndrei Pelinescu-Onciul <andrei@iptel.org>
Fri, 26 Nov 2004 16:27:22 +0000 (16:27 +0000)
committerAndrei Pelinescu-Onciul <andrei@iptel.org>
Fri, 26 Nov 2004 16:27:22 +0000 (16:27 +0000)
pt.h

diff --git a/pt.h b/pt.h
index e6fa583..797021c 100644 (file)
--- a/pt.h
+++ b/pt.h
@@ -72,18 +72,15 @@ inline static int process_count()
                /* receivers and attendant */
                (dont_fork ? 1 : children_no*udp_listeners + 1)
                /* timer process */
-               + (timer_list ? 1 : 0 )
+               + 1 /* always, we need it in most cases, and we can't tell here
+                          & now if we don't need it */
                /* fifo server */
                +((fifo==NULL || strlen(fifo)==0) ? 0 : 1 )
                /* unixsock server*/
                +(unixsock_name?unixsock_children:0)
 #ifdef USE_TCP
-               +((!tcp_disable)?( 1/* tcp main */ + tcp_children_no + 
-                                                       (timer_list ? 0: 1)):0) /* add the timer proc.
-                                                                                                         if not already taken
-                                                                                                         into account */
+               +((!tcp_disable)?( 1/* tcp main */ + tcp_children_no ):0) 
 #endif
-               
                ;
 }