]> git.ipfire.org Git - thirdparty/squid.git/commitdiff
Temporary fix for coredumps during shutdown cleanup. take06
authorAlex Rousskov <rousskov@measurement-factory.com>
Thu, 21 Apr 2011 15:19:31 +0000 (09:19 -0600)
committerAlex Rousskov <rousskov@measurement-factory.com>
Thu, 21 Apr 2011 15:19:31 +0000 (09:19 -0600)
For a permanent fix, we need to avoid deleting fd_table while it is still
in use by others, such as DeferredReads, possibly by allowing event loop
to run during shutdown.

src/comm.cc

index b92dc8e92f1808174cafc85d1594641af30d124d..67ea17a06a5f82976744b2ccd67f73f6343f5a52 100644 (file)
@@ -144,7 +144,7 @@ fd_debug_t *fdd_table = NULL;
 bool
 isOpen(const int fd)
 {
-    return fd >= 0 && fd_table[fd].flags.open != 0;
+    return fd >= 0 && fd_table && fd_table[fd].flags.open != 0;
 }
 
 /**