RFR - 8166747: Add invalid network / computer name cases to isReachable known failure switch

Rob McKenna rob.mckenna at oracle.com
Mon Sep 26 23:09:22 UTC 2016

Hi folks,

Looking for a review of this simple addition to Inet4AddressImpl.c on Windows. As per the bug report:

In the ping4() call in Inet4AddressImpl.c on Windows there is a switch statement containing failure codes for IcmpSendEcho which correspond to well known and expected failures for this call when a host is not reachable. In these cases ping4() simply returns false as opposed to throwing an exception.

Prior releases of the JDK would return false when using the tcp ping method where we currently throw an exception with the ERROR_INVALID_COMPUTERNAME (Windows error code 1210) or ERROR_INVALID_NETNAME (1214) errors. We should add these cases to the switch statement for compatibility purposes.



More information about the net-dev mailing list