]> git.ipfire.org Git - thirdparty/squid.git/commitdiff
Bug 4291: workaround DeferredReadManager::popHead segfault during shutdown
authorLubos Uhliarik <luhliari@redhat.com>
Mon, 13 Jun 2016 12:50:25 +0000 (00:50 +1200)
committerAmos Jeffries <squid3@treenet.co.nz>
Mon, 13 Jun 2016 12:50:25 +0000 (00:50 +1200)
src/comm.cc

index 8feeede537a89de467e221fa59459acdd0ad7c11..b6ecf05d5bcba34e46981d00e66c5ae213374fb4 100644 (file)
@@ -1774,7 +1774,7 @@ DeferredReadManager::popHead(CbDataListContainer<DeferredRead> &deferredReads)
     //       amount of time. We must re-validate that it is active and usable.
 
     // If the connection has been closed already. Cancel this read.
-    if (!Comm::IsConnOpen(read.theRead.conn)) {
+    if (!fd_table || !Comm::IsConnOpen(read.theRead.conn)) {
         if (read.closer != NULL) {
             read.closer->cancel("Connection closed before.");
             read.closer = NULL;