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

masaori 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 6ecc998  closing http2 state as draining http2 connection
6ecc998 is described below

commit 6ecc9983010434942c339c0756d6d08ad3bd68b0
Author: Zizhong Zhang <zizh...@linkedin.com>
AuthorDate: Wed Jun 7 22:07:34 2017 -0700

    closing http2 state as draining http2 connection
---
 proxy/http2/Http2ConnectionState.cc | 13 ++++++++-----
 1 file changed, 8 insertions(+), 5 deletions(-)

diff --git a/proxy/http2/Http2ConnectionState.cc 
b/proxy/http2/Http2ConnectionState.cc
index 16ed21d..30a2412 100644
--- a/proxy/http2/Http2ConnectionState.cc
+++ b/proxy/http2/Http2ConnectionState.cc
@@ -1158,11 +1158,14 @@ Http2ConnectionState::release_stream(Http2Stream 
*stream)
         vc->add_to_keep_alive_queue();
       }
     }
-
-    if ((fini_received || shutdown_state == IN_PROGRESS) && 
total_client_streams_count == 0) {
-      // We were shutting down, go ahead and terminate the session
-      ua_session->destroy();
-      ua_session = nullptr;
+    if (total_client_streams_count == 0) {
+      if (fini_received) {
+        // We were shutting down, go ahead and terminate the session
+        ua_session->destroy();
+        ua_session = nullptr;
+      } else if (shutdown_state == IN_PROGRESS) {
+        this_ethread()->schedule_imm_local((Continuation *)this, 
HTTP2_SESSION_EVENT_FINI);
+      }
     }
   }
 }

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

Reply via email to