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

[trafficserver] branch 7.1.x updated: TransformVC may be double closed because there is a issue within HttpTunnel::chain_abort_all

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

zwoop pushed a commit to branch 7.1.x
in repository https://gitbox.apache.org/repos/asf/trafficserver.git


The following commit(s) were added to refs/heads/7.1.x by this push:
     new 6a1e787  TransformVC may be double closed because there is a issue within HttpTunnel::chain_abort_all
6a1e787 is described below

commit 6a1e787e55781e7ec3c41026700c8999d3d3c5e6
Author: Oknet Xu <xu...@skyguard.com.cn>
AuthorDate: Fri Dec 8 11:30:02 2017 +0800

    TransformVC may be double closed because there is a issue within HttpTunnel::chain_abort_all
    
    This is a hack way to avoid double close on TVC.
    The double close issue within HttpTunnel::chain_abort_all is not
    resolved.
    
    (cherry picked from commit 49c903b0c13a2fd2c085325f6942326c4f9c926a)
---
 proxy/InkAPI.cc    | 1 +
 proxy/Transform.cc | 5 +++++
 2 files changed, 6 insertions(+)

diff --git a/proxy/InkAPI.cc b/proxy/InkAPI.cc
index f2a94f8..15fbe00 100644
--- a/proxy/InkAPI.cc
+++ b/proxy/InkAPI.cc
@@ -1177,6 +1177,7 @@ INKVConnInternal::do_io_close(int error)
 
   if (m_output_vc) {
     m_output_vc->do_io_close(error);
+    m_output_vc = nullptr;
   }
 
   eventProcessor.schedule_imm(this, ET_NET);
diff --git a/proxy/Transform.cc b/proxy/Transform.cc
index ef21d7c..fcb2f78 100644
--- a/proxy/Transform.cc
+++ b/proxy/Transform.cc
@@ -458,6 +458,10 @@ TransformVConnection::do_io_close(int error)
 {
   Debug("transform", "TransformVConnection do_io_close: %d [0x%lx]", error, (long)this);
 
+  if (m_closed != 0) {
+    return;
+  }
+
   if (error != -1) {
     m_closed = TS_VC_CLOSE_ABORT;
   } else {
@@ -465,6 +469,7 @@ TransformVConnection::do_io_close(int error)
   }
 
   m_transform->do_io_close(error);
+  m_transform = nullptr;
 }
 
 /*-------------------------------------------------------------------------

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