< prev index next >

src/java.base/share/classes/sun/nio/ch/Net.java

Print this page

        

*** 48,58 **** import java.security.AccessController; import java.security.PrivilegedAction; import java.util.Enumeration; import sun.net.ext.ExtendedSocketOptions; - import sun.net.util.IPAddressUtil; import sun.security.action.GetPropertyAction; public class Net { private Net() { } --- 48,57 ----
*** 461,473 **** static void bind(ProtocolFamily family, FileDescriptor fd, InetAddress addr, int port) throws IOException { boolean preferIPv6 = isIPv6Available() && (family != StandardProtocolFamily.INET); - if (addr.isLinkLocalAddress()) { - addr = IPAddressUtil.toScopedAddress(addr); - } bind0(fd, preferIPv6, exclusiveBind, addr, port); } private static native void bind0(FileDescriptor fd, boolean preferIPv6, boolean useExclBind, InetAddress addr, --- 460,469 ----
*** 483,495 **** } static int connect(ProtocolFamily family, FileDescriptor fd, InetAddress remote, int remotePort) throws IOException { - if (remote.isLinkLocalAddress()) { - remote = IPAddressUtil.toScopedAddress(remote); - } boolean preferIPv6 = isIPv6Available() && (family != StandardProtocolFamily.INET); return connect0(preferIPv6, fd, remote, remotePort); } --- 479,488 ----
< prev index next >