6884837: JTReg test SetOutgoingIf is not correct
Summary: Added check of network interfaces status
Reviewed-by: alanb, chegar
--- a/jdk/test/java/net/MulticastSocket/SetOutgoingIf.java Thu Sep 24 21:35:34 2009 +0800
+++ b/jdk/test/java/net/MulticastSocket/SetOutgoingIf.java Wed Sep 30 11:49:10 2009 +0200
@@ -70,7 +70,8 @@
//
List<NetworkInterface> nics = new ArrayList<NetworkInterface>();
for (NetworkInterface nic : Collections.list(NetworkInterface.getNetworkInterfaces())) {
- if (!nic.isLoopback())
+ // we should use only network interfaces with multicast support which are in "up" state
+ if (!nic.isLoopback() && nic.supportsMulticast() && nic.isUp())
nics.add(nic);
}
if (nics.size() <= 1) {