Hi Chris,
On 02/04/2020 09:40, Chris Hegarty wrote:
This is a functional change that affects the product build. Maybe that
would be a little clearer from a different bug synopsis. Suggest
something like:
Improve heuristic to determine default network interface on macOS
I can do that - or I can split the change if needed: that is push
the changes to DefaultInterface on its on?
Maybe I should add an @bug 8241786 to some of these tests too.
webrev:
http://cr.openjdk.java.net/~dfuchs/webrev_8241786/webrev.01/
DefaultInterface.java
Unless I'm mistaken, the first IPv4+IPv6+nonLinkLocal interface is not
necessarily returned.
Damn. Good catch! But that's your bug Chris: it was already there :-)
http://cr.openjdk.java.net/~dfuchs/webrev_8241786/webrev.02
includes yours and Alan's feedback.
-- daniel
The second will be returned if there are two such
interfaces. I'm not saying that this is necessarily a problem, just
trying to reconsile the code with the comment. Maybe the `preferred` can
be skipped, just returning such an IPv4+IPv6+nonLinkLocal if found.
-Chris.