From: Alex Rousskov Date: Fri, 9 May 2014 04:45:54 +0000 (-0600) Subject: Temporary fix for segmentation faults in FwdState::serverClosed debugging. X-Git-Tag: SQUID_3_5_0_1~239 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=8ed213368b7a9bb61888e38dcae787d5cec728c0;p=thirdparty%2Fsquid.git Temporary fix for segmentation faults in FwdState::serverClosed debugging. See r13404 for details. --- diff --git a/src/FwdState.cc b/src/FwdState.cc index 1fd52ade58..8dc6595849 100644 --- a/src/FwdState.cc +++ b/src/FwdState.cc @@ -619,9 +619,10 @@ FwdState::checkRetriable() void FwdState::serverClosed(int fd) { + // XXX: fd is often -1 here debugs(17, 2, "FD " << fd << " " << entry->url() << " after " << - fd_table[fd].pconn.uses << " requests"); - if (fd >= 0 && serverConnection()->fd == fd) // XXX: fd is often -1 here + (fd >= 0 ? fd_table[fd].pconn.uses : -1) << " requests"); + if (fd >= 0 && serverConnection()->fd == fd) fwdPconnPool->noteUses(fd_table[fd].pconn.uses); retryOrBail(); }