test/jdk/com/sun/net/httpserver/bugs/B6361557.java
changeset 54086 ccb4a50bee06
parent 47216 71c04702a3d5
child 54681 edd709e64ea1
equal deleted inserted replaced
54085:ab87b06dfdc0 54086:ccb4a50bee06
     1 /*
     1 /*
     2  * Copyright (c) 2006, 2010, Oracle and/or its affiliates. All rights reserved.
     2  * Copyright (c) 2006, 2019, Oracle and/or its affiliates. All rights reserved.
     3  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
     3  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
     4  *
     4  *
     5  * This code is free software; you can redistribute it and/or modify it
     5  * This code is free software; you can redistribute it and/or modify it
     6  * under the terms of the GNU General Public License version 2 only, as
     6  * under the terms of the GNU General Public License version 2 only, as
     7  * published by the Free Software Foundation.
     7  * published by the Free Software Foundation.
    76         ExecutorService executor = Executors.newCachedThreadPool();
    76         ExecutorService executor = Executors.newCachedThreadPool();
    77         server.setExecutor (executor);
    77         server.setExecutor (executor);
    78         server.start ();
    78         server.start ();
    79 
    79 
    80         InetSocketAddress destaddr = new InetSocketAddress (
    80         InetSocketAddress destaddr = new InetSocketAddress (
    81                 "127.0.0.1", server.getAddress().getPort()
    81                 InetAddress.getLoopbackAddress(), server.getAddress().getPort()
    82         );
    82         );
    83         System.out.println ("destaddr " + destaddr);
    83         System.out.println ("destaddr " + destaddr);
    84 
    84 
    85         Selector selector = Selector.open ();
    85         Selector selector = Selector.open ();
    86         int requests = 0;
    86         int requests = 0;