java/nio/channels/SocketChannel/AsyncCloseChannel.java

Please review this trivial fix to make this test run in othervm to bring Mach 5 back to green.
bug: https://bugs.openjdk.java.net/browse/JDK-8213576

This test fails repeatedly in Mach 5 on osx-x64 (JDK-8213235) recently, and the issue JDK-8213235is still under investigation.

Thanks,
Amy


--- old/test/jdk/java/nio/channels/SocketChannel/AsyncCloseChannel.java 2018-11-09 10:40:02.000000000 +0800 +++ new/test/jdk/java/nio/channels/SocketChannel/AsyncCloseChannel.java 2018-11-09 10:40:01.000000000 +0800
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2006, 2008, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2006, 2018, Oracle and/or its affiliates. All rights reserved.
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  *
  * This code is free software; you can redistribute it and/or modify it
@@ -24,13 +24,16 @@
 /* @test
  * @bug 6285901 6501089
  * @summary Check no data is written to wrong socket channel during async closing.
- * @author Xueming Shen
+ * @run main/othervm AsyncCloseChannel
  */

-import java.io.*;
-import java.nio.*;
-import java.nio.channels.*;
-import java.net.*;
+import java.io.IOException;
+import java.net.InetSocketAddress;
+import java.net.ServerSocket;
+import java.net.Socket;
+import java.nio.ByteBuffer;
+import java.nio.channels.ClosedChannelException;
+import java.nio.channels.SocketChannel;

 public class AsyncCloseChannel {
     static volatile boolean failed = false;




Reply via email to