Closed
Conversation
Contributor
|
* Use `getaddrinfo()` instead of `gethostbyname()`
I wonder how many systems supporting gethostbyname() do not have
getaddrinfo()?
…--
Snoring is prohibited unless all bedroom windows are closed and securely
locked.
[real standing law in Massachusetts, United States of America]
/// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\
/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
\\\ an exciting new programming language -- http://www.Zimbu.org ///
\\\ help me help AIDS victims -- http://ICCF-Holland.org ///
|
Contributor
Author
I don't know... should do as the following by the configure checking? If the environment supports |
b9698cd to
5380f53
Compare
Contributor
|
> I wonder how many systems supporting gethostbyname() do not have
> getaddrinfo()?
I don't know... should do as the following by the configure checking?
If the environment supports `getaddrinfo()`: use `getaddrinfo()` and
enable IPv6
Otherwise: use `gethostbyname()` and only IPv4 (same as current)
Unless we are sure 99% of systems have get getaddrinfo() I think we
should have a confire check for it and fall back to the older
implementation when not available.
…--
A parent can be arrested if his child cannot hold back a burp during a church
service.
[real standing law in Nebraska, United States of America]
/// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\
/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
\\\ an exciting new programming language -- http://www.Zimbu.org ///
\\\ help me help AIDS victims -- http://ICCF-Holland.org ///
|
Fix to include arpa/inet.h for inet_ntop()
To prevent name resolution service from being invoked in the environment where AI_NUMERICSERV is not defined.
5380f53 to
5788d92
Compare
Contributor
Author
|
Contributor
|
This looks like it's complete. Is it ready to include now? |
Contributor
Author
Yes, all set. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
getaddrinfo()instead ofgethostbyname()ch_open()accept IPv6 address (enable to parse IPv6 literal inchannel_open_func())CheckIPv6command for IPv6 tests to check loopback device has IPv6 addressg:testfuncvariable to refer the executing test name in testing: in order to switch test-server script (below) in channel testsgetaddrinfo()check and remove libnsl check sincegetaddrinfo()doesn't need libnsl.