]> granicus.if.org Git - apache/commitdiff
Actually allow the admin to set thread_limit higher than the default.
authorColm MacCarthaigh <colm@apache.org>
Wed, 31 Aug 2005 16:01:13 +0000 (16:01 +0000)
committerColm MacCarthaigh <colm@apache.org>
Wed, 31 Aug 2005 16:01:13 +0000 (16:01 +0000)
Also, initialise the first_ variables, since they are tested in the
set_ functions.

git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@265518 13f79535-47bb-0310-9956-ffa450edef68

server/mpm/worker/worker.c

index 3dfdcc270a45c8763e601211c5b0fe61daf84b59..931fb79ce3a63905a459b4fa60c1023b33c0b246 100644 (file)
@@ -120,9 +120,9 @@ static int min_spare_threads = 0;
 static int max_spare_threads = 0;
 static int ap_daemons_limit = 0;
 static int server_limit = DEFAULT_SERVER_LIMIT;
-static int first_server_limit;
+static int first_server_limit = 0;
 static int thread_limit = DEFAULT_THREAD_LIMIT;
-static int first_thread_limit;
+static int first_thread_limit = 0;
 static int changed_limit_at_restart;
 static int dying = 0;
 static int workers_may_exit = 0;
@@ -2097,7 +2097,7 @@ static const char *set_threads_per_child (cmd_parms *cmd, void *dummy,
     }
 
     ap_threads_per_child = atoi(arg);
-    if (ap_threads_per_child > thread_limit) {
+    if (first_thread_limit && ap_threads_per_child > thread_limit) {
         ap_log_error(APLOG_MARK, APLOG_STARTUP, 0, NULL, 
                      "WARNING: ThreadsPerChild of %d exceeds ThreadLimit "
                      "value of %d", ap_threads_per_child,