Re: Question about getaddrinfo in Inet4AddressImpl.c

2011-11-22 Thread Neil Richards
On Tue, 2011-11-22 at 10:49 +, Chris Hegarty wrote: > Neil, > > I filed: > CR 7114558: "Inet4AddressImpl should use memset (rather than bzero) and > NI_MAXHOST (rather than MAXHOSTNAMELEN)" > > And also reviewed your webrev. Looks fine. > > -Chris. Hi Chris, Thanks for reviewing this for m

Re: Question about getaddrinfo in Inet4AddressImpl.c

2011-11-22 Thread Chris Hegarty
Neil, I filed: CR 7114558: "Inet4AddressImpl should use memset (rather than bzero) and NI_MAXHOST (rather than MAXHOSTNAMELEN)" And also reviewed your webrev. Looks fine. -Chris. On 11/22/11 10:00 AM, Neil Richards wrote: On Tue, 2011-11-22 at 09:38 +, Chris Hegarty wrote: Let me know

Re: Question about getaddrinfo in Inet4AddressImpl.c

2011-11-22 Thread Neil Richards
On Tue, 2011-11-22 at 09:38 +, Chris Hegarty wrote: > Let me know the details synopsis/descriptions/etc and I'll file a new > CR. I'm guessing its just some cleanup/style issues, right? > > -Chris. I've uploaded a webrev with the gap between the two [1]. The differences are the use of memse

Re: Question about getaddrinfo in Inet4AddressImpl.c

2011-11-22 Thread Chris Hegarty
On 11/22/11 09:27 AM, Neil Richards wrote: Hi Chris, Thank you for creating the bug id for this issue. I've now pushed the change [1]. However, I've just realised I've foolishly pushed a previous version of the change, and not the final agreed version. (aargh!) No problem. This happens f

Re: Question about getaddrinfo in Inet4AddressImpl.c

2011-11-22 Thread Neil Richards
On Wed, 2011-11-16 at 20:57 +, Chris Hegarty wrote: > Thank you Charles, and Neil. > > I ran some builds and tests and all looks good to me. Thanks for fixing > the warnings, I know they were not caused by your changes. > > Just noticed that we haven't just filed a bug for this, so I just cr

Re: Question about getaddrinfo in Inet4AddressImpl.c

2011-11-16 Thread Charles Lee
On 11/17/2011 04:57 AM, Chris Hegarty wrote: On 11/16/11 01:48 AM, Charles Lee wrote: On 11/16/2011 01:00 AM, Neil Richards wrote: On Tue, 2011-11-15 at 19:37 +0800, Charles Lee wrote: On 11/15/2011 07:10 PM, Chris Hegarty wrote: On 11/15/11 06:57 AM, Charles Lee wrote: Sigh. Chris, I s

Re: Question about getaddrinfo in Inet4AddressImpl.c

2011-11-16 Thread Chris Hegarty
On 11/16/11 01:48 AM, Charles Lee wrote: On 11/16/2011 01:00 AM, Neil Richards wrote: On Tue, 2011-11-15 at 19:37 +0800, Charles Lee wrote: On 11/15/2011 07:10 PM, Chris Hegarty wrote: On 11/15/11 06:57 AM, Charles Lee wrote: Sigh. Chris, I still fail to see those warnings, even if I do

Re: Question about getaddrinfo in Inet4AddressImpl.c

2011-11-15 Thread Charles Lee
On 11/16/2011 01:00 AM, Neil Richards wrote: On Tue, 2011-11-15 at 19:37 +0800, Charles Lee wrote: On 11/15/2011 07:10 PM, Chris Hegarty wrote: On 11/15/11 06:57 AM, Charles Lee wrote: Sigh. Chris, I still fail to see those warnings, even if I do a very clean remove of my build directory

Re: Question about getaddrinfo in Inet4AddressImpl.c

2011-11-15 Thread Neil Richards
On Tue, 2011-11-15 at 19:37 +0800, Charles Lee wrote: > On 11/15/2011 07:10 PM, Chris Hegarty wrote: > > On 11/15/11 06:57 AM, Charles Lee wrote: > >> > > >>> > >> Sigh. Chris, I still fail to see those warnings, even if I do a very > >> clean remove of my build directory and rebuild the

Re: Question about getaddrinfo in Inet4AddressImpl.c

2011-11-15 Thread Charles Lee
On 11/15/2011 07:10 PM, Chris Hegarty wrote: On 11/15/11 06:57 AM, Charles Lee wrote: Sigh. Chris, I still fail to see those warnings, even if I do a very clean remove of my build directory and rebuild the whole jdk The warning are being generated on Solaris when using the Sun

Re: Question about getaddrinfo in Inet4AddressImpl.c

2011-11-15 Thread Chris Hegarty
On 11/15/11 06:57 AM, Charles Lee wrote: Sigh. Chris, I still fail to see those warnings, even if I do a very clean remove of my build directory and rebuild the whole jdk The warning are being generated on Solaris when using the Sun compilers ( both full and incremental builds )

Re: Question about getaddrinfo in Inet4AddressImpl.c

2011-11-14 Thread Charles Lee
On 11/14/2011 10:15 PM, Chris Hegarty wrote: I agree with Mikes comments, and here are a few of trivial ones of my own. - 'struct sockaddr_in6 him6' here is unused in getHostByAddr - caddr[16] - > caddr[4] in getHostByAddr Thanks for making this change. It really cleans up this old code. It

Re: Question about getaddrinfo in Inet4AddressImpl.c

2011-11-14 Thread Charles Lee
On 11/14/2011 10:15 PM, Chris Hegarty wrote: I agree with Mikes comments, and here are a few of trivial ones of my own. - 'struct sockaddr_in6 him6' here is unused in getHostByAddr - caddr[16] - > caddr[4] in getHostByAddr Thanks for making this change. It really cleans up this old code. It

Re: Question about getaddrinfo in Inet4AddressImpl.c

2011-11-14 Thread Chris Hegarty
I agree with Mikes comments, and here are a few of trivial ones of my own. - 'struct sockaddr_in6 him6' here is unused in getHostByAddr - caddr[16] - > caddr[4] in getHostByAddr Thanks for making this change. It really cleans up this old code. It is not your fault as the same is in Inet6Addre

Re: Question about getaddrinfo in Inet4AddressImpl.c

2011-11-13 Thread Charles Lee
On 11/12/2011 04:07 AM, Mike Duigou wrote: Some comments: Inet4AddressImpl.c: - why use bzero rather than posix memset? - MAXHOSTNAMELEN is used. Shouldn't this be NI_MAXHOST as in the Inet6 version? Mike On Nov 11 2011, at 06:53 , Neil Richards wrote: On Wed, 2011-11-09 at 12:19 +0800, Ch

Re: Question about getaddrinfo in Inet4AddressImpl.c

2011-11-11 Thread Mike Duigou
Some comments: Inet4AddressImpl.c: - why use bzero rather than posix memset? - MAXHOSTNAMELEN is used. Shouldn't this be NI_MAXHOST as in the Inet6 version? Mike On Nov 11 2011, at 06:53 , Neil Richards wrote: > On Wed, 2011-11-09 at 12:19 +0800, Charles Lee wrote: >> On 11/09/2011 03:25 AM,

Re: Question about getaddrinfo in Inet4AddressImpl.c

2011-11-11 Thread Neil Richards
On Wed, 2011-11-09 at 12:19 +0800, Charles Lee wrote: > On 11/09/2011 03:25 AM, Chris Hegarty wrote: > > Charles, > > > > Is it possible to fix up the style issues, etc that Neil pointed out, > > and have the webrev updated? > > > Hi Chris, > > Here it is. (attached) > And here it is, in webre

Re: Question about getaddrinfo in Inet4AddressImpl.c

2011-11-08 Thread Charles Lee
On 11/09/2011 03:25 AM, Chris Hegarty wrote: Charles, Is it possible to fix up the style issues, etc that Neil pointed out, and have the webrev updated? Thanks, -Chris. On 11/ 8/11 01:44 PM, Charles Lee wrote: On 11/03/2011 12:33 AM, Neil Richards wrote: On Wed, 2011-11-02 at 23:07 +0800,

Re: Question about getaddrinfo in Inet4AddressImpl.c

2011-11-08 Thread Chris Hegarty
Charles, Is it possible to fix up the style issues, etc that Neil pointed out, and have the webrev updated? Thanks, -Chris. On 11/ 8/11 01:44 PM, Charles Lee wrote: On 11/03/2011 12:33 AM, Neil Richards wrote: On Wed, 2011-11-02 at 23:07 +0800, Charles Lee wrote: On 10/26/2011 06:31 PM, Ch

Re: Question about getaddrinfo in Inet4AddressImpl.c

2011-11-08 Thread Charles Lee
On 11/03/2011 12:33 AM, Neil Richards wrote: On Wed, 2011-11-02 at 23:07 +0800, Charles Lee wrote: On 10/26/2011 06:31 PM, Chris Hegarty wrote: On 26/10/2011 10:36, Alan Bateman wrote: On 26/10/2011 10:24, Charles Lee wrote: />>> I don't think this code has changed too much since then and p

Re: Question about getaddrinfo in Inet4AddressImpl.c

2011-11-06 Thread Charles Lee
On 11/03/2011 12:33 AM, Neil Richards wrote: On Wed, 2011-11-02 at 23:07 +0800, Charles Lee wrote: On 10/26/2011 06:31 PM, Chris Hegarty wrote: On 26/10/2011 10:36, Alan Bateman wrote: On 26/10/2011 10:24, Charles Lee wrote: />>> I don't think this code has changed too much since then and p

Re: Question about getaddrinfo in Inet4AddressImpl.c

2011-11-02 Thread Neil Richards
On Wed, 2011-11-02 at 23:07 +0800, Charles Lee wrote: > On 10/26/2011 06:31 PM, Chris Hegarty wrote: > > On 26/10/2011 10:36, Alan Bateman wrote: > >> On 26/10/2011 10:24, Charles Lee wrote: > >>> > >>> > >>> />>> I don't think this code has changed too much since then and > >>> probably could do w

Re: Question about getaddrinfo in Inet4AddressImpl.c

2011-11-02 Thread Charles Lee
On 10/26/2011 06:31 PM, Chris Hegarty wrote: On 26/10/2011 10:36, Alan Bateman wrote: On 26/10/2011 10:24, Charles Lee wrote: />>> I don't think this code has changed too much since then and probably could do with a clean-up./ Not true. I'm talking about the InetAddress* code, that hasn't ch

Re: Question about getaddrinfo in Inet4AddressImpl.c

2011-11-02 Thread Charles Lee
On 10/26/2011 06:31 PM, Chris Hegarty wrote: On 26/10/2011 10:36, Alan Bateman wrote: On 26/10/2011 10:24, Charles Lee wrote: />>> I don't think this code has changed too much since then and probably could do with a clean-up./ Not true. I'm talking about the InetAddress* code, that hasn't ch

Re: Question about getaddrinfo in Inet4AddressImpl.c

2011-10-27 Thread Charles Lee
On 10/26/2011 06:31 PM, Chris Hegarty wrote: On 26/10/2011 10:36, Alan Bateman wrote: On 26/10/2011 10:24, Charles Lee wrote: />>> I don't think this code has changed too much since then and probably could do with a clean-up./ Not true. I'm talking about the InetAddress* code, that hasn't ch

Re: Question about getaddrinfo in Inet4AddressImpl.c

2011-10-27 Thread Charles Lee
On 10/26/2011 05:36 PM, Alan Bateman wrote: On 26/10/2011 10:24, Charles Lee wrote: />>> I don't think this code has changed too much since then and probably could do with a clean-up./ Not true. I'm talking about the InetAddress* code, that hasn't changed significantly and probably could do

Re: Question about getaddrinfo in Inet4AddressImpl.c

2011-10-26 Thread Chris Hegarty
On 26/10/2011 10:36, Alan Bateman wrote: On 26/10/2011 10:24, Charles Lee wrote: />>> I don't think this code has changed too much since then and probably could do with a clean-up./ Not true. I'm talking about the InetAddress* code, that hasn't changed significantly and probably could do with

Re: Question about getaddrinfo in Inet4AddressImpl.c

2011-10-26 Thread Alan Bateman
On 26/10/2011 10:24, Charles Lee wrote: />>> I don't think this code has changed too much since then and probably could do with a clean-up./ Not true. I'm talking about the InetAddress* code, that hasn't changed significantly and probably could do with some modernization now. -Alan.

Re: Question about getaddrinfo in Inet4AddressImpl.c

2011-10-26 Thread Charles Lee
On 10/26/2011 04:30 PM, Alan Bateman wrote: On 26/10/2011 08:47, Charles Lee wrote: But I do not get getaddrinfo is ipv6 specified. Do I miss sth? If I recall correctly, when the support for IPv6 was added (predates OpenJDK as it was jdk1.4, as in 10 years ago) then getaddrinfo/getnameinfo/etc

Re: Question about getaddrinfo in Inet4AddressImpl.c

2011-10-26 Thread Alan Bateman
On 26/10/2011 08:47, Charles Lee wrote: But I do not get getaddrinfo is ipv6 specified. Do I miss sth? If I recall correctly, when the support for IPv6 was added (predates OpenJDK as it was jdk1.4, as in 10 years ago) then getaddrinfo/getnameinfo/etc. wasn't not widely supported and if I think

Re: Question about getaddrinfo in Inet4AddressImpl.c

2011-10-26 Thread Charles Lee
On 10/25/2011 05:41 PM, Chris Hegarty wrote: On 10/25/11 08:31 AM, Charles Lee wrote: Hi guys, I am reading some native code in the jdk repos. I find that in Inet4AddressImpl.c (folder solaris), gethostbyname is used. Meanwhile in the Inet6AddressImpl.c. getaddrinfo is used. My question is why

Re: Question about getaddrinfo in Inet4AddressImpl.c

2011-10-25 Thread Jonathan Lu
Hello Chris, On 10/25/2011 05:41 PM, Chris Hegarty wrote: On 10/25/11 08:31 AM, Charles Lee wrote: Hi guys, I am reading some native code in the jdk repos. I find that in Inet4AddressImpl.c (folder solaris), gethostbyname is used. Meanwhile in the Inet6AddressImpl.c. getaddrinfo is used. My q

Re: Question about getaddrinfo in Inet4AddressImpl.c

2011-10-25 Thread Chris Hegarty
On 10/25/11 08:31 AM, Charles Lee wrote: Hi guys, I am reading some native code in the jdk repos. I find that in Inet4AddressImpl.c (folder solaris), gethostbyname is used. Meanwhile in the Inet6AddressImpl.c. getaddrinfo is used. My question is why inet4 does not use getaddrinfo? Any concern h