hc-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bugzi...@apache.org
Subject DO NOT REPLY [Bug 27242] - "Socket Closed" IOException thrown by HttpConnection
Date Thu, 26 Feb 2004 09:17:19 GMT
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG 
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://nagoya.apache.org/bugzilla/show_bug.cgi?id=27242>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND 
INSERTED IN THE BUG DATABASE.

http://nagoya.apache.org/bugzilla/show_bug.cgi?id=27242

"Socket Closed" IOException thrown by HttpConnection





------- Additional Comments From olegk@apache.org  2004-02-26 09:17 -------
Petri,
I do not quite see how the allegedly offending change may be causing this problem

http://cvs.apache.org/viewcvs.cgi/jakarta-commons/httpclient/src/java/org/apache/commons/httpclient/HttpClient.java?r1=1.76.2.2&r2=1.76.2.3&diff_format=h&only_with_tag=HTTPCLIENT_2_0_BRANCH

True, in 2.0-final connection.setSoTimeout() is called before the
connection.isOpen() check. However in both 2.0rc3 & 2.0-final the call occurs
BEFORE the socket is actually open. I do not quite see how it would be possible
for a socket closed IOException to be thrown with 2.0-final but not with
2.0-rc3. Am I missing something?

What kind of JDK are you using? I suspect that this problem can well be JDK
specific, as I always thought that it was okay to call setSoTimeout() on a
closed socket.

Anyhow, in case of HttpClient#executeMethod the call to
connection.setSoTimeout() does seem misplaced. The method should be called only
after the connection is open.

---------------------------------------------------------------------
To unsubscribe, e-mail: commons-httpclient-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: commons-httpclient-dev-help@jakarta.apache.org


Mime
View raw message