This is an automated email from the ASF dual-hosted git repository.

oknet pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/trafficserver.git


The following commit(s) were added to refs/heads/master by this push:
     new 5642ab2  fix the number of started threads of certain type.
5642ab2 is described below

commit 5642ab204d5ddc1145a0d567a3044eabee539e68
Author: Oknet Xu <xuc...@skyguard.com.cn>
AuthorDate: Fri Aug 10 00:46:30 2018 +0800

    fix the number of started threads of certain type.
---
 iocore/eventsystem/UnixEventProcessor.cc | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/iocore/eventsystem/UnixEventProcessor.cc 
b/iocore/eventsystem/UnixEventProcessor.cc
index 8344650..10a4efd 100644
--- a/iocore/eventsystem/UnixEventProcessor.cc
+++ b/iocore/eventsystem/UnixEventProcessor.cc
@@ -394,8 +394,8 @@ EventProcessor::initThreadState(EThread *t)
 {
   // Run all thread type initialization continuations that match the event 
types for this thread.
   for (int i = 0; i < MAX_EVENT_TYPES; ++i) {
-    thread_group[i]._started++;
     if (t->is_event_type(i)) { // that event type done here, roll thread start 
events of that type.
+      ++thread_group[i]._started;
       // To avoid race conditions on the event in the spawn queue, create a 
local one to actually send.
       // Use the spawn queue event as a read only model.
       Event *nev = eventAllocator.alloc();

Reply via email to