Proposed fix for 6660405.

Jean-Christophe Collet Jean-Christophe.Collet at Sun.COM
Wed Mar 5 07:27:25 PST 2008


Here is my proposed fix for CR 6660405.
The issue is that after a redirect, and if there is a cache hit (i.e. 
the URL is found in the cache) HttpURLConnection will return the wrong 
InputStream. Details are in the evaluation section of the CR.
My proposed fix is to set inputStream back to null in 
sun.net.www.protocol.http.HttpURLConnection.disconnectInternal().
I've also included a regression test that reproduces the bug.
See patch attached.

-------------- next part --------------
A non-text attachment was scrubbed...
Name: jdk.patch
Type: text/x-patch
Size: 5896 bytes
Desc: not available
Url : http://mail.openjdk.java.net/pipermail/net-dev/attachments/20080305/63852c7a/jdk.patch 


More information about the net-dev mailing list