You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@trafficserver.apache.org by sh...@apache.org on 2016/06/15 19:12:06 UTC

[trafficserver] branch master updated: [TS-4529] Adjust thread with the right continuation. This closes #703.

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

shinrich pushed a commit to branch master
in repository https://git-dual.apache.org/repos/asf/trafficserver.git

The following commit(s) were added to refs/heads/master by this push:
       new  bb4d873   [TS-4529] Adjust thread with the right continuation. This closes #703.
bb4d873 is described below

commit bb4d873356a7760044f026c09811ae41134fc751
Author: David Calavera <da...@gmail.com>
AuthorDate: Mon Jun 13 09:49:15 2016 -0700

    [TS-4529] Adjust thread with the right continuation. This closes #703.
    
    Signed-off-by: David Calavera <da...@gmail.com>
---
 proxy/ProxyClientTransaction.cc | 4 ++--
 proxy/ProxyClientTransaction.h  | 2 +-
 proxy/http/HttpSM.cc            | 4 ++--
 3 files changed, 5 insertions(+), 5 deletions(-)

diff --git a/proxy/ProxyClientTransaction.cc b/proxy/ProxyClientTransaction.cc
index 067bb93..f33f712 100644
--- a/proxy/ProxyClientTransaction.cc
+++ b/proxy/ProxyClientTransaction.cc
@@ -86,13 +86,13 @@ ProxyClientTransaction::attach_server_session(HttpServerSession *ssession, bool
 }
 
 Action *
-ProxyClientTransaction::adjust_thread(int event, void *data)
+ProxyClientTransaction::adjust_thread(Continuation *cont, int event, void *data)
 {
   NetVConnection *vc = this->get_netvc();
   EThread *this_thread = this_ethread();
   if (vc && vc->thread != this_thread) {
     if (vc->thread->is_event_type(ET_NET) || vc->thread->is_event_type(SSLNetProcessor::ET_SSL)) {
-      return vc->thread->schedule_imm(this, event, data);
+      return vc->thread->schedule_imm(cont, event, data);
     } else { // Not a net thread, take over this thread
       vc->thread = this_thread;
     }
diff --git a/proxy/ProxyClientTransaction.h b/proxy/ProxyClientTransaction.h
index e724aaf..f2bbcb9 100644
--- a/proxy/ProxyClientTransaction.h
+++ b/proxy/ProxyClientTransaction.h
@@ -51,7 +51,7 @@ public:
 
   // See if we need to schedule on the primary thread for the transaction or change the thread that is associated with the VC.
   // If we reschedule, the scheduled action is returned.  Otherwise, NULL is returned
-  Action *adjust_thread(int event, void *data);
+  Action *adjust_thread(Continuation *cont, int event, void *data);
 
   int
   get_transact_count() const
diff --git a/proxy/http/HttpSM.cc b/proxy/http/HttpSM.cc
index 1668db3..202e4b8 100644
--- a/proxy/http/HttpSM.cc
+++ b/proxy/http/HttpSM.cc
@@ -2437,7 +2437,7 @@ HttpSM::state_cache_open_write(int event, void *data)
 
   // Make sure we are on the "right" thread
   if (ua_session) {
-    if ((pending_action = ua_session->adjust_thread(event, data))) {
+    if ((pending_action = ua_session->adjust_thread(this, event, data))) {
       return 0; // Go away if we reschedule
     }
   }
@@ -4643,7 +4643,7 @@ HttpSM::do_http_server_open(bool raw)
 
   // Make sure we are on the "right" thread
   if (ua_session) {
-    if ((pending_action = ua_session->adjust_thread(EVENT_INTERVAL, NULL))) {
+    if ((pending_action = ua_session->adjust_thread(this, EVENT_INTERVAL, NULL))) {
       return; // Go away if we reschedule
     }
   }

-- 
To stop receiving notification emails like this one, please contact
['"commits@trafficserver.apache.org" <co...@trafficserver.apache.org>'].