trafficserver-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From a..@apache.org
Subject trafficserver git commit: TS-4258: NULL out server_session when it is destroyed. This closes #513.
Date Tue, 08 Mar 2016 16:17:44 GMT
Repository: trafficserver
Updated Branches:
  refs/heads/master 5e53b85e6 -> a4b37105c


TS-4258: NULL out server_session when it is destroyed.
This closes #513.


Project: http://git-wip-us.apache.org/repos/asf/trafficserver/repo
Commit: http://git-wip-us.apache.org/repos/asf/trafficserver/commit/a4b37105
Tree: http://git-wip-us.apache.org/repos/asf/trafficserver/tree/a4b37105
Diff: http://git-wip-us.apache.org/repos/asf/trafficserver/diff/a4b37105

Branch: refs/heads/master
Commit: a4b37105c2bae7490b2761db39228a2c6b9b2cea
Parents: 5e53b85
Author: Alan M. Carroll <amc@apache.org>
Authored: Sat Mar 5 10:33:50 2016 -0600
Committer: Alan M. Carroll <amc@apache.org>
Committed: Tue Mar 8 10:17:18 2016 -0600

----------------------------------------------------------------------
 proxy/http/HttpSM.cc | 8 +++++---
 1 file changed, 5 insertions(+), 3 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/trafficserver/blob/a4b37105/proxy/http/HttpSM.cc
----------------------------------------------------------------------
diff --git a/proxy/http/HttpSM.cc b/proxy/http/HttpSM.cc
index 1787714..4b18dbc 100644
--- a/proxy/http/HttpSM.cc
+++ b/proxy/http/HttpSM.cc
@@ -2981,6 +2981,7 @@ HttpSM::tunnel_handler_server(int event, HttpTunnelProducer *p)
 
   if (close_connection) {
     p->vc->do_io_close();
+    server_session = NULL; // Because p->vc == server_session
     p->read_vio = NULL;
     /* TS-1424: if we're outbound transparent and using the client
        source port for the outbound connection we must effectively
@@ -3053,9 +3054,10 @@ HttpSM::is_bg_fill_necessary(HttpTunnelConsumer *c)
 {
   ink_assert(c->vc_type == HT_HTTP_CLIENT);
 
-  if (c->producer->alive &&                                              //
something there to read
-      server_entry && server_entry->vc && server_session->get_netvc()
&& // from an origin server
-      c->producer->num_consumers > 1                                     // with
someone else reading it
+  if (c->producer->alive &&                            // something there to
read
+      server_entry && server_entry->vc &&              // from an origin
server
+      server_session && server_session->get_netvc() && // which is still
open and valid
+      c->producer->num_consumers > 1                   // with someone else reading
it
       ) {
     // If threshold is 0.0 or negative then do background
     //   fill regardless of the content length.  Since this


Mime
View raw message