RFR: 8275640 (win) java.net.NetworkInterface issues with IPv6-only environments [v4]

Daniel Jeliński djelinski at openjdk.java.net
Mon Feb 7 09:19:11 UTC 2022


On Wed, 19 Jan 2022 08:15:46 GMT, Daniel Jeliński <djelinski at openjdk.org> wrote:

>> Why?
>> No users of `enumInterfaces` rely on the value returned in the second parameter when `enumInterfaces` returns a negative result. The same is true for `getAllInterfacesAndAddresses`.
>> The second parameter was NULL-initialized in a few places; this initialization was not necessary and I just removed it to avoid confusion.
>
> ahh... I see your point now. I missed a few cases where the returned value was referenced (free'd) even though the function failed. These should be fixed now.

Added null-initialization of return values on function entry.

-------------

PR: https://git.openjdk.java.net/jdk/pull/6090


More information about the net-dev mailing list