Details
-
Bug
-
Resolution: Fixed
-
P4
-
7, 8, 9, 11
-
b12
-
x86
-
os_x
Description
Apple JDK 6 throws a PortUnreachableException immediately.
import java.net.*;
public class A1 {
public static void main(String[] args) throws Exception {
byte[] data = "hello".getBytes();
InetAddress iaddr = InetAddress.getByName("localhost");
DatagramSocket dgSocket = new DatagramSocket();
dgSocket.setSoTimeout(5000);
dgSocket.connect(iaddr, 8080);
DatagramPacket dgPacketOut = new DatagramPacket(data, data.length,
iaddr, 8080);
dgSocket.send(dgPacketOut);
byte ibuf[] = new byte[1024];
DatagramPacket dgPacketIn = new DatagramPacket(ibuf, ibuf.length);
dgSocket.receive(dgPacketIn);
}
}
Attachments
Issue Links
- relates to
-
JDK-8278229 com/sun/jndi/dns/ConfigTests/PortUnreachable.java fails with javax.naming.CommunicationException
- Open
-
JDK-8005793 Connected UDP sockets are not actually connected on a Macintosh
- Resolved
-
JDK-8256427 Test com/sun/jndi/dns/ConfigTests/PortUnreachable.java does not work on AIX
- Resolved
-
JDK-7122794 (macosx) DatagramSocket.disconnect() not working
- Closed
-
JDK-8015595 Test sun/security/krb5/auto/Unreachable.java fails with Timeout error
- Closed
-
JDK-7143960 java/net/DatagramSocket/SendDatagramToBadAddress.java is failing on Mac OS X
- Closed
-
JDK-7162687 enhance KDC server availability detection
- Closed