RFR(S): 8171075: Inet4AddressImpl: Remove duplicate and (no longer used ?) native coding for BSD

Langer, Christoph christoph.langer at sap.com
Mon Dec 19 14:32:00 UTC 2016


Hi Chris,

interesting finding - I have to admit that I didn't pay attention to that detail.

But I think the removed implementation anyway was rather unused and obsolete. Both, the other version in IPv4 impl and the one in IPv6 impl would not reverse the order, so nothing should change in behavior.

The more exciting change is 8171077 which changes IPv4 impl on windows from gethostbyaddr to getaddrinfo. Though still that one only touches IPv4 impl while the IPv6 impl version has already been using getaddrinfo for a long time and I think is used in most cases nowadays anyway as the IPv6 stack is mostly available. Looking forward to a review of that one...

Thanks for looking & best regards
Christoph

> -----Original Message-----
> From: Chris Hegarty [mailto:chris.hegarty at oracle.com]
> Sent: Montag, 19. Dezember 2016 15:07
> To: Langer, Christoph <christoph.langer at sap.com>
> Cc: Lindenmaier, Goetz <goetz.lindenmaier at sap.com>; OpenJDK Network Dev
> list <net-dev at openjdk.java.net>
> Subject: Re: RFR(S): 8171075: Inet4AddressImpl: Remove duplicate and (no
> longer used ?) native coding for BSD
> 
> Hi Christoph,
> 
> On 19/12/16 08:37, Langer, Christoph wrote:
> > Thanks for the review, Goetz.
> >
> > I pushed it: http://hg.openjdk.java.net/jdk9/dev/jdk/rev/3edecfdfe4de
> 
> Sorry I didn't get to this before now. I think the changes are
> good. Trivially, the array return by lookupAllHostAddr will now
> always be in ordered as per getaddrinfo ( not sure why the order
> was ever reversed ).
> 
> -Chris.
> 
> > Best regards
> > Christoph
> >
> >> -----Original Message-----
> >> From: Lindenmaier, Goetz
> >> Sent: Freitag, 16. Dezember 2016 11:11
> >> To: Langer, Christoph <christoph.langer at sap.com>; 'Michael McMahon'
> >> <michael.x.mcmahon at oracle.com>; Chris Hegarty
> >> <chris.hegarty at oracle.com>; OpenJDK Network Dev list <net-
> >> dev at openjdk.java.net>
> >> Subject: RE: RFR(S): 8171075: Inet4AddressImpl: Remove duplicate and (no
> >> longer used ?) native coding for BSD
> >>
> >> Hi Christioph,
> >>
> >> I had a look at your change.
> >>
> >> The code you remove is only used if __GLIBC__ is not defined
> >> _and_ it's FreeBSD older than 6.11.
> >> The removed code is basically identical to the other code. You
> >> added the fallback to lookupIfIfLocalhost() to the shared code
> >> guarded by MACOSX which makes sense.
> >>
> >> Looks good.
> >>
> >> Thanks,
> >>   Goetz.
> >>
> >>
> >>
> >>> From: Langer, Christoph
> >>> Sent: Montag, 12. Dezember 2016 11:06
> >>> To: 'Michael McMahon' <michael.x.mcmahon at oracle.com>; Chris
> Hegarty
> >>> <chris.hegarty at oracle.com>; OpenJDK Network Dev list <net-
> >>> dev at openjdk.java.net>
> >>> Subject: RFR(S): 8171075: Inet4AddressImpl: Remove duplicate and (no
> longer
> >>> used ?) native coding for BSD
> >>>
> >>> Michael, Chris,
> >>>
> >>> please have a look at this. This is the subset from 8167420 that removes
> the
> >>> obsolete BSD coding.
> >>>
> >>> Bug: https://bugs.openjdk.java.net/browse/JDK-8171075
> >>>
> >>> Webrev: http://cr.openjdk.java.net/~clanger/webrevs/8171075.0/
> >>>
> >>> Thanks,
> >>> Christoph
> >>>
> >>>
> >


More information about the net-dev mailing list