mirror of
https://github.com/openjdk/jdk.git
synced 2026-05-20 10:27:52 +00:00
7150539: HttpURLConnection.getResponseMessage() doesn't throw IOException on server error (OS X)
Reviewed-by: michaelm, alanb
This commit is contained in:
parent
e3f4248c42
commit
49605b7bf9
@ -55,8 +55,8 @@ public class RetryPost
|
||||
void doClient() {
|
||||
try {
|
||||
InetSocketAddress address = httpServer.getAddress();
|
||||
URL url = new URL("http://" + address.getHostName() + ":" + address.getPort() + "/test/");
|
||||
HttpURLConnection uc = (HttpURLConnection)url.openConnection();
|
||||
URL url = new URL("http://localhost:" + address.getPort() + "/test/");
|
||||
HttpURLConnection uc = (HttpURLConnection)url.openConnection(Proxy.NO_PROXY);
|
||||
uc.setDoOutput(true);
|
||||
uc.setRequestMethod("POST");
|
||||
uc.getResponseCode();
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user