From: Yann Ylavic Date: Fri, 3 Aug 2018 10:27:18 +0000 (+0000) Subject: event, worker: follow up to r1835845, r1837354: pruntime is global now. X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=7a471fe745f63841d42beab7932ec43a6963c2fc;p=apache event, worker: follow up to r1835845, r1837354: pruntime is global now. git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1837356 13f79535-47bb-0310-9956-ffa450edef68 --- diff --git a/server/mpm/event/event.c b/server/mpm/event/event.c index 03c3e7d338..47053a7d7b 100644 --- a/server/mpm/event/event.c +++ b/server/mpm/event/event.c @@ -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; } diff --git a/server/mpm/worker/worker.c b/server/mpm/worker/worker.c index da6c6030a6..6fad701bee 100644 --- a/server/mpm/worker/worker.c +++ b/server/mpm/worker/worker.c @@ -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) {