8285836: sun/net/www/http/KeepAliveCache/KeepAliveProperty.java failed with "RuntimeException: Failed in server"
Reviewed-by: dfuchs, jpai
This commit is contained in:
parent
b7d2bde8e3
commit
af529be069
@ -40,6 +40,7 @@ import static java.net.Proxy.NO_PROXY;
|
|||||||
public class KeepAliveProperty {
|
public class KeepAliveProperty {
|
||||||
|
|
||||||
static volatile boolean pass = false;
|
static volatile boolean pass = false;
|
||||||
|
static Logger logger = Logger.getLogger("sun.net.www.protocol.http.HttpURLConnection");
|
||||||
|
|
||||||
static class Server extends Thread {
|
static class Server extends Thread {
|
||||||
final ServerSocket server;
|
final ServerSocket server;
|
||||||
@ -138,7 +139,6 @@ public class KeepAliveProperty {
|
|||||||
|
|
||||||
public static void main(String args[]) throws Exception {
|
public static void main(String args[]) throws Exception {
|
||||||
// exercise the logging code
|
// exercise the logging code
|
||||||
Logger logger = Logger.getLogger("sun.net.www.protocol.http.HttpURLConnection");
|
|
||||||
logger.setLevel(Level.FINEST);
|
logger.setLevel(Level.FINEST);
|
||||||
ConsoleHandler h = new ConsoleHandler();
|
ConsoleHandler h = new ConsoleHandler();
|
||||||
h.setLevel(Level.FINEST);
|
h.setLevel(Level.FINEST);
|
||||||
@ -171,6 +171,7 @@ public class KeepAliveProperty {
|
|||||||
if (!expectClose)
|
if (!expectClose)
|
||||||
throw e;
|
throw e;
|
||||||
}
|
}
|
||||||
|
s.join();
|
||||||
|
|
||||||
if (!pass)
|
if (!pass)
|
||||||
throw new RuntimeException("Failed in server");
|
throw new RuntimeException("Failed in server");
|
||||||
|
Loading…
x
Reference in New Issue
Block a user