JDK-8234266 : Release Note: DatagramSocket.send and MulticastSocket.send Throw IllegalArgumentException When Socket Is Not Connected and Packet Doesn't Contain Address
  • Type: Sub-task
  • Component: core-libs
  • Sub-Component: java.net
  • Affected Version: 14
  • Priority: P4
  • Status: Closed
  • Resolution: Delivered
  • Submitted: 2019-11-15
  • Updated: 2020-04-27
  • Resolved: 2019-11-18
The Version table provides details related to the release that this issue/RFE will be addressed.

Unresolved : Release in which this issue/RFE will be addressed.
Resolved: Release in which this issue/RFE has been resolved.
Fixed : Release in which this issue/RFE has been fixed. The release containing this fix may be available for download as an Early Access Release or a General Availability Release.

To download the current JDK release, click here.
JDK 14
14Resolved
Description
The `send` methods defined by `DatagramSocket` and `MulticastSocket` have been changed to throw an `IllegalArgumentException` if the socket is not connected and the `DatagramPacket` doesn't have a socket address. Prior to this change, these methods threw a `NullPointerException`.