Author: olegk Date: Thu Jul 21 13:24:06 2005 New Revision: 220179 URL: http://svn.apache.org/viewcvs?rev=220179&view=rev Log: PR #32333 (Connection not closed after "Connection: close" request)
Back-ported from HttpClient 3.0 by Eric Johnson Modified: jakarta/commons/proper/httpclient/branches/HTTPCLIENT_2_0_BRANCH/release_notes.txt jakarta/commons/proper/httpclient/branches/HTTPCLIENT_2_0_BRANCH/src/java/org/apache/commons/httpclient/HttpMethodBase.java Modified: jakarta/commons/proper/httpclient/branches/HTTPCLIENT_2_0_BRANCH/release_notes.txt URL: http://svn.apache.org/viewcvs/jakarta/commons/proper/httpclient/branches/HTTPCLIENT_2_0_BRANCH/release_notes.txt?rev=220179&r1=220178&r2=220179&view=diff ============================================================================== --- jakarta/commons/proper/httpclient/branches/HTTPCLIENT_2_0_BRANCH/release_notes.txt (original) +++ jakarta/commons/proper/httpclient/branches/HTTPCLIENT_2_0_BRANCH/release_notes.txt Thu Jul 21 13:24:06 2005 @@ -1,5 +1,9 @@ Changes since Release 2.0.2 + * 32333 - Connection is now closed upon "Connection: close" request, + if the server does not include an explicit connection + directive in the response + * 34721 - Virtual host setting is now correctly applied when parsing and matching cookies Modified: jakarta/commons/proper/httpclient/branches/HTTPCLIENT_2_0_BRANCH/src/java/org/apache/commons/httpclient/HttpMethodBase.java URL: http://svn.apache.org/viewcvs/jakarta/commons/proper/httpclient/branches/HTTPCLIENT_2_0_BRANCH/src/java/org/apache/commons/httpclient/HttpMethodBase.java?rev=220179&r1=220178&r2=220179&view=diff ============================================================================== --- jakarta/commons/proper/httpclient/branches/HTTPCLIENT_2_0_BRANCH/src/java/org/apache/commons/httpclient/HttpMethodBase.java (original) +++ jakarta/commons/proper/httpclient/branches/HTTPCLIENT_2_0_BRANCH/src/java/org/apache/commons/httpclient/HttpMethodBase.java Thu Jul 21 13:24:06 2005 @@ -906,6 +906,11 @@ if (connectionHeader == null) { connectionHeader = responseHeaders.getFirstHeader("connection"); } + // In case the response does not contain any explict connection + // directives, check whether the request does + if (connectionHeader == null) { + connectionHeader = requestHeaders.getFirstHeader("connection"); + } if (connectionHeader != null) { if (connectionHeader.getValue().equalsIgnoreCase("close")) { if (LOG.isDebugEnabled()) { --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]