httpd-cvs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From cove...@apache.org
Subject svn commit: r1588806 - /httpd/httpd/trunk/server/mpm/event/event.c
Date Sun, 20 Apr 2014 17:53:38 GMT
Author: covener
Date: Sun Apr 20 17:53:38 2014
New Revision: 1588806

URL: http://svn.apache.org/r1588806
Log:
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.


Modified:
    httpd/httpd/trunk/server/mpm/event/event.c

Modified: httpd/httpd/trunk/server/mpm/event/event.c
URL: http://svn.apache.org/viewvc/httpd/httpd/trunk/server/mpm/event/event.c?rev=1588806&r1=1588805&r2=1588806&view=diff
==============================================================================
--- httpd/httpd/trunk/server/mpm/event/event.c (original)
+++ httpd/httpd/trunk/server/mpm/event/event.c Sun Apr 20 17:53:38 2014
@@ -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);
 



Mime
View raw message