10 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
11 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
12 * version 2 for more details (a copy is included in the LICENSE file that
13 * accompanied this code).
14 *
15 * You should have received a copy of the GNU General Public License version
16 * 2 along with this work; if not, write to the Free Software Foundation,
17 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
18 *
19 * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
20 * or visit www.oracle.com if you need additional information or have any
21 * questions.
22 */
23
24 /*
25 * @test
26 * @bug 4469866
27 * @summary Connecting to a link-local IPv6 address should not
28 * causes a SocketException to be thrown.
29 * @library /test/lib
30 * @run main LinkLocal
31 */
32
33 import jdk.test.lib.NetworkConfiguration;
34
35 import java.net.*;
36 import java.util.List;
37 import java.util.stream.Collectors;
38
39 public class LinkLocal {
40
41 static int testCount = 0;
42 static int failed = 0;
43
44 static void TcpTest(InetAddress ia) throws Exception {
45 System.out.println("**************************************");
46 testCount++;
47 System.out.println("Test " + testCount + ": TCP connect to " + ia);
48
49 /*
|
10 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
11 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
12 * version 2 for more details (a copy is included in the LICENSE file that
13 * accompanied this code).
14 *
15 * You should have received a copy of the GNU General Public License version
16 * 2 along with this work; if not, write to the Free Software Foundation,
17 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
18 *
19 * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
20 * or visit www.oracle.com if you need additional information or have any
21 * questions.
22 */
23
24 /*
25 * @test
26 * @bug 4469866
27 * @summary Connecting to a link-local IPv6 address should not
28 * causes a SocketException to be thrown.
29 * @library /test/lib
30 * @build jdk.test.lib.NetworkConfiguration
31 * jdk.test.lib.Utils
32 * jdk.test.lib.Asserts
33 * jdk.test.lib.JDKToolFinder
34 * jdk.test.lib.JDKToolLauncher
35 * jdk.test.lib.Platform
36 * jdk.test.lib.process.*
37 * @run main LinkLocal
38 */
39
40 import jdk.test.lib.NetworkConfiguration;
41
42 import java.net.*;
43 import java.util.List;
44 import java.util.stream.Collectors;
45
46 public class LinkLocal {
47
48 static int testCount = 0;
49 static int failed = 0;
50
51 static void TcpTest(InetAddress ia) throws Exception {
52 System.out.println("**************************************");
53 testCount++;
54 System.out.println("Test " + testCount + ": TCP connect to " + ia);
55
56 /*
|