From: Nathan Hoad Date: Tue, 18 Feb 2014 08:55:04 +0000 (-0700) Subject: Bug 4026: SSL and adaptation_access does not handle aborted connections X-Git-Tag: SQUID_3_4_4~13 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=74f5e1cf78d6b7f96571a4746deb4cbf4452c3d8;p=thirdparty%2Fsquid.git Bug 4026: SSL and adaptation_access does not handle aborted connections --- diff --git a/src/client_side_request.cc b/src/client_side_request.cc index 45e26ff7a6..073af4f964 100644 --- a/src/client_side_request.cc +++ b/src/client_side_request.cc @@ -848,11 +848,12 @@ ClientHttpRequest::noteAdaptationAclCheckDone(Adaptation::ServiceGroupPointer g) #if ICAP_CLIENT Adaptation::Icap::History::Pointer ih = request->icapHistory(); if (ih != NULL) { - if (getConn() != NULL) { + if (getConn() != NULL && getConn()->clientConnection != NULL) { ih->rfc931 = getConn()->clientConnection->rfc931; #if USE_SSL - assert(getConn()->clientConnection != NULL); - ih->ssluser = sslGetUserEmail(fd_table[getConn()->clientConnection->fd].ssl); + if (getConn()->clientConnection->isOpen()) { + ih->ssluser = sslGetUserEmail(fd_table[getConn()->clientConnection->fd].ssl); + } #endif } ih->log_uri = log_uri;