--- a/test/jdk/java/net/URLConnection/contentHandler/UserContentHandler.java Thu Sep 26 14:41:09 2019 -0700
+++ b/test/jdk/java/net/URLConnection/contentHandler/UserContentHandler.java Fri Sep 27 09:55:35 2019 +0100
@@ -40,6 +40,7 @@
import java.io.*;
import java.util.*;
import jdk.test.lib.net.URIBuilder;
+import static java.net.Proxy.NO_PROXY;
public class UserContentHandler implements Runnable {
@@ -98,7 +99,7 @@
.path("/anything.txt")
.toURL();
- if (!(u.openConnection().getContent() instanceof String)) {
+ if (!(u.openConnection(NO_PROXY).getContent() instanceof String)) {
throw new RuntimeException("Load user defined content handler failed.");
} else {
System.err.println("Load user defined content handler succeed!");