File tree Expand file tree Collapse file tree 1 file changed +7
-1
lines changed Expand file tree Collapse file tree 1 file changed +7
-1
lines changed Original file line number Diff line number Diff line change 11/*
2- * Copyright (c) 2023, Alibaba Group Holding Limited. All Rights Reserved.
2+ * Copyright (c) 2023, 2025, Alibaba Group Holding Limited. All Rights Reserved.
33 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
44 *
55 * This code is free software; you can redistribute it and/or modify it
2626 * @bug 8312065
2727 * @summary Socket.connect does not timeout as expected when profiling (i.e. keep receiving signal)
2828 * @requires (os.family != "windows")
29+ * @library /test/lib
30+ * @build jtreg.SkippedException
2931 * @compile NativeThread.java
3032 * @run main/othervm/native/timeout=120 B8312065
3133 */
3739import java .net .SocketTimeoutException ;
3840import java .util .concurrent .TimeUnit ;
3941
42+ import jtreg .SkippedException ;
43+
4044public class B8312065 {
4145 public static void main (String [] args ) throws Exception {
4246 System .loadLibrary ("NativeThread" );
@@ -83,6 +87,8 @@ public static void main(String[] args) throws Exception {
8387 System .out .println ("Test FAILED: duration " + duration + " ms, expected >= " + timeoutMillis + " ms" );
8488 System .exit (1 );
8589 }
90+ } catch (java .net .ConnectException e ) {
91+ throw new SkippedException ("Network setup issue, skip this test" , e );
8692 }
8793 }
8894}
You can’t perform that action at this time.
0 commit comments