The return value from the getFlags() method in NetworkInterface.c is interpreted in 2 ways. - If the value is negative an Exception is thrown - Else the return value is considered as the flag mask obtained via the ioctl call. In rare cases is it possible the value in the ifr_flags could be negative. One such case is VIPA interfaces on AIX. AIX defines VIPA interface flag as "0x80000000", any calls like isUp() on such network interfaces would end up in a Socket Exception. Here is a similar bug report related to FreeBSD http://hg.openjdk.java.net/macosx-port/macosx-port/jdk/rev/c6334146005c see full discussion on net-dev mailing list: http://mail.openjdk.java.net/pipermail/net-dev/2012-August/004650.html
|