Code Review Request: 7035556 DatagramSocket.java:183: warning: unreachable catch clause (original) (raw)

Alan Bateman Alan.Bateman at oracle.com
Fri Jul 22 06:55:28 PDT 2011


Michael McMahon wrote:

But, bind() already closes the impl internally before throwing the exception. I was wondering about that and whether this is a bug. Suppose someone creates an unbound DatagramSocket and then attempts to bind it to a port. If the bind fails (say port already in use) then it may be surprising that they can't retry with a different port. Should this be specified? I see there are cases such as the security exception where it doesn't the close the impl.

-Alan. -------------- next part -------------- An HTML attachment was scrubbed... URL: http://mail.openjdk.java.net/pipermail/net-dev/attachments/20110722/4763e460/attachment.html



More information about the net-dev mailing list