From 360c8f35f505ae3a95334dc818d6cbe8e2762033 Mon Sep 17 00:00:00 2001 From: Eric Covener Date: Sun, 20 Apr 2014 17:53:38 +0000 Subject: [PATCH] r1494157 from eventopt for event, per sf's review comments. use a subpool of pchild since skiplist allocations will happen across threads and are only protected from other skiplist operations. git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1588806 13f79535-47bb-0310-9956-ffa450edef68 --- server/mpm/event/event.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/server/mpm/event/event.c b/server/mpm/event/event.c index be90c7df30..29c261c1d4 100644 --- a/server/mpm/event/event.c +++ b/server/mpm/event/event.c @@ -2345,6 +2345,7 @@ static void child_main(int child_num_arg) thread_starter *ts; apr_threadattr_t *thread_attr; apr_thread_t *start_thread_id; + apr_pool_t *pskip; mpm_state = AP_MPMQ_STARTING; /* for benefit of any hooks that run as this * child initializes @@ -2362,7 +2363,8 @@ static void child_main(int child_num_arg) apr_thread_mutex_create(&g_timer_skiplist_mtx, APR_THREAD_MUTEX_DEFAULT, pchild); APR_RING_INIT(&timer_free_ring, timer_event_t, link); - apr_skiplist_init(&timer_skiplist, pchild); + apr_pool_create(&pskip, pchild); + apr_skiplist_init(&timer_skiplist, pskip); apr_skiplist_set_compare(timer_skiplist, indexing_comp, indexing_compk); ap_run_child_init(pchild, ap_server_conf); -- 2.50.1