]> granicus.if.org Git - apache/commitdiff
event, worker: follow up to r1835845, r1837354: pruntime is global now.
authorYann Ylavic <ylavic@apache.org>
Fri, 3 Aug 2018 10:27:18 +0000 (10:27 +0000)
committerYann Ylavic <ylavic@apache.org>
Fri, 3 Aug 2018 10:27:18 +0000 (10:27 +0000)
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1837356 13f79535-47bb-0310-9956-ffa450edef68

server/mpm/event/event.c
server/mpm/worker/worker.c

index 03c3e7d338953c0c9321ae5caccb87b7e06e8394..47053a7d7b5676a454cb71486ee08dac6d00eff9 100644 (file)
@@ -2408,7 +2408,7 @@ static int check_signal(int signum)
     return 0;
 }
 
-static void create_listener_thread(thread_starter * ts, apr_pool_t *pool)
+static void create_listener_thread(thread_starter * ts)
 {
     int my_child_num = ts->child_num_arg;
     apr_threadattr_t *thread_attr = ts->threadattr;
@@ -2419,7 +2419,7 @@ static void create_listener_thread(thread_starter * ts, apr_pool_t *pool)
     my_info->pslot = my_child_num;
     my_info->tslot = -1;      /* listener thread doesn't have a thread slot */
     rv = apr_thread_create(&ts->listener, thread_attr, listener_thread,
-                           my_info, pool);
+                           my_info, pruntime);
     if (rv != APR_SUCCESS) {
         ap_log_error(APLOG_MARK, APLOG_ALERT, rv, ap_server_conf, APLOGNO(00474)
                      "apr_thread_create: unable to create listener thread");
@@ -2627,7 +2627,7 @@ static void *APR_THREAD_FUNC start_threads(apr_thread_t * thd, void *dummy)
 
         /* Start the listener only when there are workers available */
         if (!listener_started && threads_created) {
-            create_listener_thread(ts, pruntime);
+            create_listener_thread(ts);
             listener_started = 1;
         }
 
index da6c6030a639d149c76ff2d69a44f56d406241b9..6fad701beeeaa290ebe497532bc94b953fb2a055 100644 (file)
@@ -835,7 +835,7 @@ static int check_signal(int signum)
     return 0;
 }
 
-static void create_listener_thread(thread_starter *ts, apr_pool_t *pool)
+static void create_listener_thread(thread_starter *ts)
 {
     int my_child_num = ts->child_num_arg;
     apr_threadattr_t *thread_attr = ts->threadattr;
@@ -847,7 +847,7 @@ static void create_listener_thread(thread_starter *ts, apr_pool_t *pool)
     my_info->tid = -1; /* listener thread doesn't have a thread slot */
     my_info->sd = 0;
     rv = apr_thread_create(&ts->listener, thread_attr, listener_thread,
-                           my_info, pool);
+                           my_info, pruntime);
     if (rv != APR_SUCCESS) {
         ap_log_error(APLOG_MARK, APLOG_ALERT, rv, ap_server_conf, APLOGNO(00275)
                      "apr_thread_create: unable to create listener thread");
@@ -978,7 +978,7 @@ static void * APR_THREAD_FUNC start_threads(apr_thread_t *thd, void *dummy)
         }
         /* Start the listener only when there are workers available */
         if (!listener_started && threads_created) {
-            create_listener_thread(ts, pruntime);
+            create_listener_thread(ts);
             listener_started = 1;
         }
         if (start_thread_may_exit || threads_created == threads_per_child) {