mirror of
https://github.com/openjdk/jdk.git
synced 2026-04-20 20:00:28 +00:00
8022212: Intermittent test failures in java/net
Reviewed-by: chegar
This commit is contained in:
parent
4fe266b9f7
commit
d45f6482a3
@ -33,11 +33,16 @@ import java.util.Enumeration;
|
||||
import static java.lang.System.out;
|
||||
|
||||
public class IndexTest {
|
||||
static final boolean isWindows = System.getProperty("os.name").startsWith("Windows");
|
||||
|
||||
public static void main(String[] args) throws Exception {
|
||||
Enumeration<NetworkInterface> netifs = NetworkInterface.getNetworkInterfaces();
|
||||
NetworkInterface nif = null;
|
||||
NetworkInterface nif;
|
||||
while (netifs.hasMoreElements()) {
|
||||
nif = netifs.nextElement();
|
||||
// JDK-8022212, Skip (Windows) Teredo Tunneling seudo-Interface
|
||||
if (nif.getDisplayName().contains("Teredo") && isWindows)
|
||||
continue;
|
||||
int index = nif.getIndex();
|
||||
if (index >= 0) {
|
||||
NetworkInterface nif2 = NetworkInterface.getByIndex(index);
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user