mirror of
https://github.com/moparisthebest/curl
synced 2024-12-21 15:48:49 -05:00
code/docs: Use correct case for IPv4 and IPv6
For consistency, as we seem to have a bit of a mixed bag, changed all instances of ipv4 and ipv6 in comments and documentations to use the correct case.
This commit is contained in:
parent
bde08d216c
commit
151ae59436
58
CHANGES.0
58
CHANGES.0
@ -267,7 +267,7 @@ Daniel Stenberg (16 Apr 2010)
|
||||
Daniel Stenberg (15 Apr 2010)
|
||||
- Rainer Canavan filed bug report #2987196 that identified libcurl doing
|
||||
unnecesary reverse name lookups in many cases when built to use IPv4 and
|
||||
getaddrinfo(). The logic for ipv6 is now used for ipv4 too.
|
||||
getaddrinfo(). The logic for IPv6 is now used for IPv4 too.
|
||||
|
||||
(http://curl.haxx.se/bug/view.cgi?id=2963679)
|
||||
|
||||
@ -4271,7 +4271,7 @@ Daniel S (15 Nov 2007)
|
||||
list.
|
||||
|
||||
- Michal Marek fixed the test suite to better deal with the case when the HTTP
|
||||
ipv6 server can't run.
|
||||
IPv6 server can't run.
|
||||
|
||||
Yang Tse (14 Nov 2007)
|
||||
- Fix a variable potential wrapping in add_buffer() when using absolutely
|
||||
@ -6109,7 +6109,7 @@ Daniel (22 August 2006)
|
||||
- David McCreedy fixed a remaining mistake from the August 19 TYPE change.
|
||||
|
||||
- Peter Sylvester pointed out a flaw in the AllowServerConnect() in the FTP
|
||||
code when doing pure ipv6 EPRT connections.
|
||||
code when doing pure IPv6 EPRT connections.
|
||||
|
||||
Daniel (19 August 2006)
|
||||
- Based on a patch by Armel Asselin, the FTP code no longer re-issues the TYPE
|
||||
@ -6666,8 +6666,8 @@ Daniel (24 January 2006)
|
||||
|
||||
Daniel (20 January 2006)
|
||||
- Duane Cathey was one of our friends who reported that curl -P [IP]
|
||||
(CURLOPT_FTPPORT) didn't work for ipv6-enabed curls if the IP wasn't a
|
||||
"native" IP while it works fine for ipv6-disabled builds!
|
||||
(CURLOPT_FTPPORT) didn't work for IPv6-enabed curls if the IP wasn't a
|
||||
"native" IP while it works fine for IPv6-disabled builds!
|
||||
|
||||
In the process of fixing this, I removed the support for LPRT since I can't
|
||||
think of many reasons to keep doing it and asking on the mailing list didn't
|
||||
@ -6676,7 +6676,7 @@ Daniel (20 January 2006)
|
||||
|
||||
Daniel (19 January 2006)
|
||||
- Jon Turner pointed out that doing -P [hostname] (CURLOPT_FTPPORT) with curl
|
||||
(built ipv4-only) didn't work.
|
||||
(built IPv4-only) didn't work.
|
||||
|
||||
Daniel (18 January 2006)
|
||||
- As reported in bug #1408742 (http://curl.haxx.se/bug/view.cgi?id=1408742),
|
||||
@ -7557,7 +7557,7 @@ Daniel (29 March 2005)
|
||||
Daniel (16 March 2005)
|
||||
- Tru64 and some IRIX boxes seem to not like test 237 as it is. Their
|
||||
inet_addr() functions seems to use &255 on all numericals in a ipv4 dotted
|
||||
address which makes a different failure... Now I've modified the ipv4
|
||||
address which makes a different failure... Now I've modified the IPv4
|
||||
resolve code to use inet_pton() instead in an attempt to make these systems
|
||||
better detect this as a bad IP address rather than creating a toally bogus
|
||||
address that is then passed on and used.
|
||||
@ -7750,7 +7750,7 @@ Daniel (7 February 2005)
|
||||
|
||||
Daniel (5 February 2005)
|
||||
- Eric Vergnaud found a use of an uninitialised variable in the ftp when doing
|
||||
PORT on ipv6-enabled hosts.
|
||||
PORT on IPv6-enabled hosts.
|
||||
|
||||
- David Byron pointed out we could use BUFSIZE to read data (in
|
||||
lib/transfer.c) instead of using BUFSIZE -1.
|
||||
@ -7822,7 +7822,7 @@ Daniel (28 January 2005)
|
||||
8. fetch a URL from the same server as before (re-using the connection)
|
||||
|
||||
- Stephen More pointed out that CURLOPT_FTPPORT and the -P option didn't work
|
||||
when built ipv6-enabled. I've now made a fix for it. Writing test cases for
|
||||
when built IPv6-enabled. I've now made a fix for it. Writing test cases for
|
||||
custom port hosts turned too tricky so unfortunately there's none.
|
||||
|
||||
Daniel (25 January 2005)
|
||||
@ -8560,9 +8560,9 @@ Daniel (20 August 2004)
|
||||
byte file is downloaded.
|
||||
|
||||
Daniel (18 August 2004)
|
||||
- Ling Thio pointed out that when libcurl is built ipv6-enabled, it still did
|
||||
- Ling Thio pointed out that when libcurl is built IPv6-enabled, it still did
|
||||
reverse DNS lookups when fed with a numerical IP-address (like
|
||||
http://127.0.0.1/), although it doesn't when built ipv6-disabled. libcurl
|
||||
http://127.0.0.1/), although it doesn't when built IPv6-disabled. libcurl
|
||||
should never do reverse lookups.
|
||||
|
||||
Daniel (17 August 2004)
|
||||
@ -8714,7 +8714,7 @@ Daniel (27 June 2004)
|
||||
Daniel (24 June 2004)
|
||||
- The standard curl_version() string now only includes version info about
|
||||
involved libraries and not about particular features. Thus it will no longer
|
||||
include info about ipv6 nor GSS. That info is of course still available in
|
||||
include info about IPv6 nor GSS. That info is of course still available in
|
||||
the feature bitmask curl_version_info() offers.
|
||||
|
||||
- Replaced all occurances of sprintf() with snprintf(). This is mostly because
|
||||
@ -8729,8 +8729,8 @@ Daniel (24 June 2004)
|
||||
|
||||
Internally, this means amongst other things that we can stop doing the weird
|
||||
"increase buffer size until it works" trick when resolving hosts on
|
||||
ipv4-only with gethostbyname_r(), we support socks even on libcurls built
|
||||
with ipv6 enabled (but only to socks servers that resolve to an ipv4
|
||||
IPv4-only with gethostbyname_r(), we support socks even on libcurls built
|
||||
with IPv6 enabled (but only to socks servers that resolve to an IPv4
|
||||
address) and we no longer deep-copy or relocate hostent structs (we create
|
||||
Curl_addrinfo chains instead).
|
||||
|
||||
@ -9074,7 +9074,7 @@ Daniel (27 April 2004)
|
||||
and proxy name to the ACE encoded version to use internally for resolves and
|
||||
cookies etc. They are now using one 'struct hostname' each that keep both
|
||||
the original name and the possibly encoded name. IDN resolves work for me
|
||||
now using ipv6, ipv4 and ares resolving. Even cookies on IDN sites seem to
|
||||
now using IPv6, IPv4 and ares resolving. Even cookies on IDN sites seem to
|
||||
do right. I got some failures at first when CHARSET wasn't set at all which
|
||||
confused libidn completely and it decided by encoding of choice was
|
||||
'ANSI_X3.4-1968'...
|
||||
@ -9115,7 +9115,7 @@ Daniel (25 April 2004)
|
||||
|
||||
CURLRES_ARES - is defined if libcurl is built to use c-ares for asynchronous
|
||||
name resolves. It cannot have ENABLE_IPV6 defined at the same time, as
|
||||
c-ares has no ipv6 support. This can be Windows or *nix.
|
||||
c-ares has no IPv6 support. This can be Windows or *nix.
|
||||
|
||||
CURLRES_THREADED - is defined if libcurl is built to run under (native)
|
||||
Windows, and then the name resolve will be done in a new thread, and the
|
||||
@ -9132,8 +9132,8 @@ Daniel (25 April 2004)
|
||||
hostsyn.c - functions for synchronous name resolves
|
||||
hostares.c - functions for ares-using name resolves
|
||||
hostthre.c - functions for threaded name resolves
|
||||
hostip4.c - ipv4-specific functions
|
||||
hostip6.c - ipv6-specific functions
|
||||
hostip4.c - IPv4 specific functions
|
||||
hostip6.c - IPv6 specific functions
|
||||
|
||||
The hostip.h is the single united header file for all this. It defines the
|
||||
CURLRES_* defines based on the config*.h and setup.h defines.
|
||||
@ -9225,7 +9225,7 @@ Daniel (15 April 2004)
|
||||
for the typical (not very deep) case.
|
||||
|
||||
Daniel (14 April 2004)
|
||||
- Asking for CURL_IPRESOLVE_V6 when ipv6 addresses can't be resolved will
|
||||
- Asking for CURL_IPRESOLVE_V6 when IPv6 addresses can't be resolved will
|
||||
now cause the resolve function to return NULL immediately. This flaw was
|
||||
pointed out by Gisle Vanem.
|
||||
|
||||
@ -9380,7 +9380,7 @@ Daniel (29 March 2004)
|
||||
- The postit2.c source example used the wrong struct name for the post data.
|
||||
|
||||
Daniel (26 March 2004)
|
||||
- Gisle Vanem improved ipv6 support on windows by making the curl build to use
|
||||
- Gisle Vanem improved IPv6 support on Windows by making the curl build use
|
||||
the correct getaddrinfo() function.
|
||||
|
||||
Daniel (25 March 2004)
|
||||
@ -9673,7 +9673,7 @@ Daniel (16 February 2004)
|
||||
and re-use that same handle during the entire curl handle's life-time. It
|
||||
improves performance.
|
||||
|
||||
- Fixed a problem when displaying verbose for ipv6-enabled libcurls and
|
||||
- Fixed a problem when displaying verbose for IPv6-enabled libcurls and
|
||||
re-used connections. Problem reported and fix verified by Grigory Entin.
|
||||
|
||||
- Jeff Lawson fixed the version-check in the SOCKS5 code.
|
||||
@ -9725,7 +9725,7 @@ Daniel (9 February 2004)
|
||||
|
||||
- Tor Arntsen provided a patch that makes libcurl work-around a bug in the
|
||||
AIX5 implementation of getaddrinfo(). This makes the FTP PORT stuff work on
|
||||
ipv6-enabled AIX builds.
|
||||
IPv6-enabled AIX builds.
|
||||
|
||||
- Ken Rastatter provided portability fixes for the curlgtk.c example, and now
|
||||
it runs on windows with GTK as well!
|
||||
@ -9754,7 +9754,7 @@ Daniel (5 February 2004)
|
||||
verifies this functionality.
|
||||
|
||||
- Tor Arntsen fixed a weird getaddrinfo() usage in the FTP code, preventing
|
||||
the ipv6-code for PORT work on AIX 5.2. We now also provide (better) error
|
||||
the IPv6-code for PORT work on AIX 5.2. We now also provide (better) error
|
||||
messages when bailing out in the that function.
|
||||
|
||||
- Tor Arntsen now provides AIX and IRIX (using gcc, xlc and the MIPSPro
|
||||
@ -10133,10 +10133,10 @@ Daniel (13 November)
|
||||
possibly other platforms too.
|
||||
|
||||
- Peter Sylvester identified a problem in the connect code, which made the
|
||||
multi interface on a ipv6-enabled solaris box do bad. Test case 504 to be
|
||||
multi interface on a IPv6-enabled Solaris box do bad. Test case 504 to be
|
||||
specific. I've spent some time to clean-up the Curl_connecthost() function
|
||||
now to use less duplicated code for the two different sections: ipv6 and
|
||||
ipv4.
|
||||
now to use less duplicated code for the two different sections: IPv6 and
|
||||
IPv4.
|
||||
|
||||
Daniel (11 November)
|
||||
- Added CURLOPT_NETRC_FILE. Use this to tell libcurl which file to use instead
|
||||
@ -10234,7 +10234,7 @@ Daniel (29 October)
|
||||
Daniel (28 October)
|
||||
- Dan C tracked down yet another weird behavior in the glibc gethostbyname_r()
|
||||
function for some specific versions (reported on 2.2.5 and 2.1.1), and
|
||||
provided a fix. On Linux machines with these glibc versions, non-ipv6
|
||||
provided a fix. On Linux machines with these glibc versions, non-IPv6
|
||||
builds of libcurl would often fail to resolve perfectly resolvable host
|
||||
names.
|
||||
|
||||
@ -10353,7 +10353,7 @@ Version 7.10.8-pre3 (8 October 2003)
|
||||
|
||||
Daniel (8 October)
|
||||
- Frank Ticheler provided a patch that fixes how libcurl connects to multiple
|
||||
addresses, if one of them fails (ipv4-code).
|
||||
addresses, if one of them fails (IPv4 code).
|
||||
|
||||
Daniel (7 October)
|
||||
- Neil Dunbar provided a patch that now makes libcurl check SSL
|
||||
@ -11865,7 +11865,7 @@ Daniel (30 Sep 2002)
|
||||
updated the man page accordingly.
|
||||
|
||||
- Cris Bailiff found out that the pre-releases crashed on name lookups on
|
||||
names such as "a:" or "baz:" (on Linux versions not being ipv6-enabled) due
|
||||
names such as "a:" or "baz:" (on Linux versions not being IPv6-enabled) due
|
||||
to some weird return codes from gethostbyname_r(). I'll blame the complete
|
||||
lack of docs in that department. Cris provided a fix, which I modified only
|
||||
slightly.
|
||||
|
@ -1064,10 +1064,10 @@ dnl **********************************************************************
|
||||
dnl Checks for IPv6
|
||||
dnl **********************************************************************
|
||||
|
||||
AC_MSG_CHECKING([whether to enable ipv6])
|
||||
AC_MSG_CHECKING([whether to enable IPv6])
|
||||
AC_ARG_ENABLE(ipv6,
|
||||
AC_HELP_STRING([--enable-ipv6],[Enable ipv6 (with ipv4) support])
|
||||
AC_HELP_STRING([--disable-ipv6],[Disable ipv6 support]),
|
||||
AC_HELP_STRING([--enable-ipv6],[Enable IPv6 (with IPv4) support])
|
||||
AC_HELP_STRING([--disable-ipv6],[Disable IPv6 support]),
|
||||
[ case "$enableval" in
|
||||
no)
|
||||
AC_MSG_RESULT(no)
|
||||
@ -3600,7 +3600,7 @@ AC_MSG_NOTICE([Configured to build curl/libcurl:
|
||||
GSS-API support: ${curl_gss_msg}
|
||||
TLS-SRP support: ${curl_tls_srp_msg}
|
||||
resolver: ${curl_res_msg}
|
||||
ipv6 support: ${curl_ipv6_msg}
|
||||
IPv6 support: ${curl_ipv6_msg}
|
||||
Unix sockets support: ${curl_unix_sockets_msg}
|
||||
IDN support: ${curl_idn_msg}
|
||||
Build libcurl: Shared=${enable_shared}, Static=${enable_static}
|
||||
|
8
docs/FAQ
8
docs/FAQ
@ -1274,7 +1274,7 @@ FAQ
|
||||
you want to change name resolver function you must rebuild libcurl and tell
|
||||
it to use a different function.
|
||||
|
||||
- The non-ipv6 resolver that can use one out of four host name resolve calls
|
||||
- The non-IPv6 resolver that can use one out of four host name resolve calls
|
||||
(depending on what your system supports):
|
||||
|
||||
A - gethostbyname()
|
||||
@ -1282,15 +1282,15 @@ FAQ
|
||||
C - gethostbyname_r() with 5 arguments
|
||||
D - gethostbyname_r() with 6 arguments
|
||||
|
||||
- The ipv6-resolver that uses getaddrinfo()
|
||||
- The IPv6-resolver that uses getaddrinfo()
|
||||
|
||||
- The c-ares based name resolver that uses the c-ares library for resolves.
|
||||
Using this offers asynchronous name resolves.
|
||||
|
||||
- The threaded resolver (default option on Windows). It uses:
|
||||
|
||||
A - gethostbyname() on plain ipv4 hosts
|
||||
B - getaddrinfo() on ipv6-enabled hosts
|
||||
A - gethostbyname() on plain IPv4 hosts
|
||||
B - getaddrinfo() on IPv6 enabled hosts
|
||||
|
||||
Also note that libcurl never resolves or reverse-lookups addresses given as
|
||||
pure numbers, such as 127.0.0.1 or ::1.
|
||||
|
@ -135,7 +135,7 @@
|
||||
|
||||
Use 'struct lifreq' and SIOCGLIFADDR instead of 'struct ifreq' and
|
||||
SIOCGIFADDR on newer Solaris versions as they claim the latter is obsolete.
|
||||
To support ipv6 interface addresses for network interfaces properly.
|
||||
To support IPv6 interface addresses for network interfaces properly.
|
||||
|
||||
1.4 signal-based resolver timeouts
|
||||
|
||||
|
@ -5,7 +5,7 @@
|
||||
* | (__| |_| | _ <| |___
|
||||
* \___|\___/|_| \_\_____|
|
||||
*
|
||||
* Copyright (C) 2012, Daniel Stenberg, <daniel@haxx.se>, et al.
|
||||
* Copyright (C) 2012 - 2014, Daniel Stenberg, <daniel@haxx.se>, et al.
|
||||
*
|
||||
* This software is licensed as described in the file COPYING, which
|
||||
* you should have received as part of this distribution. The terms
|
||||
@ -336,7 +336,7 @@ static curl_socket_t opensocket(void *clientp,
|
||||
|
||||
curl_socket_t sockfd = CURL_SOCKET_BAD;
|
||||
|
||||
/* restrict to ipv4 */
|
||||
/* restrict to IPv4 */
|
||||
if (purpose == CURLSOCKTYPE_IPCXN && address->family == AF_INET)
|
||||
{
|
||||
/* create a tcp socket object */
|
||||
|
@ -1658,8 +1658,8 @@ typedef enum {
|
||||
option might be handy to force libcurl to use a specific IP version. */
|
||||
#define CURL_IPRESOLVE_WHATEVER 0 /* default, resolves addresses to all IP
|
||||
versions that your system allows */
|
||||
#define CURL_IPRESOLVE_V4 1 /* resolve to ipv4 addresses */
|
||||
#define CURL_IPRESOLVE_V6 2 /* resolve to ipv6 addresses */
|
||||
#define CURL_IPRESOLVE_V4 1 /* resolve to IPv4 addresses */
|
||||
#define CURL_IPRESOLVE_V6 2 /* resolve to IPv6 addresses */
|
||||
|
||||
/* three convenient "aliases" that follow the name scheme better */
|
||||
#define CURLOPT_RTSPHEADER CURLOPT_HTTPHEADER
|
||||
|
@ -711,9 +711,9 @@ else
|
||||
@echo c-ares support: no
|
||||
endif
|
||||
ifdef ENABLE_IPV6
|
||||
@echo ipv6 support: enabled
|
||||
@echo IPv6 support: enabled
|
||||
else
|
||||
@echo ipv6 support: no
|
||||
@echo IPv6 support: no
|
||||
endif
|
||||
|
||||
$(CURL_INC)/curl/curlbuild.h: Makefile.netware FORCE
|
||||
|
@ -28,8 +28,8 @@
|
||||
hostsyn.c - functions for synchronous name resolves
|
||||
asyn-ares.c - functions for asynchronous name resolves using c-ares
|
||||
asyn-thread.c - functions for asynchronous name resolves using threads
|
||||
hostip4.c - ipv4-specific functions
|
||||
hostip6.c - ipv6-specific functions
|
||||
hostip4.c - IPv4 specific functions
|
||||
hostip6.c - IPv6 specific functions
|
||||
|
||||
The hostip.h is the single united header file for all this. It defines the
|
||||
CURLRES_* defines based on the config*.h and curl_setup.h defines.
|
||||
|
@ -635,7 +635,7 @@ Curl_addrinfo *Curl_resolver_getaddrinfo(struct connectdata *conn,
|
||||
}
|
||||
|
||||
if((pf != PF_INET) && !Curl_ipv6works())
|
||||
/* the stack seems to be a non-ipv6 one */
|
||||
/* The stack seems to be a non-IPv6 one */
|
||||
pf = PF_INET;
|
||||
|
||||
#endif /* CURLRES_IPV6 */
|
||||
|
@ -376,7 +376,7 @@ static CURLcode bindlocal(struct connectdata *conn,
|
||||
|
||||
if(done > 0) {
|
||||
#ifdef ENABLE_IPV6
|
||||
/* ipv6 address */
|
||||
/* IPv6 address */
|
||||
if(af == AF_INET6) {
|
||||
#ifdef HAVE_SOCKADDR_IN6_SIN6_SCOPE_ID
|
||||
char *scope_ptr = strchr(myhost, '%');
|
||||
@ -399,7 +399,7 @@ static CURLcode bindlocal(struct connectdata *conn,
|
||||
}
|
||||
else
|
||||
#endif
|
||||
/* ipv4 address */
|
||||
/* IPv4 address */
|
||||
if((af == AF_INET) &&
|
||||
(Curl_inet_pton(AF_INET, myhost, &si4->sin_addr) > 0)) {
|
||||
si4->sin_family = AF_INET;
|
||||
|
@ -41,7 +41,7 @@ long Curl_timeleft(struct SessionHandle *data,
|
||||
|
||||
#define DEFAULT_CONNECT_TIMEOUT 300000 /* milliseconds == five minutes */
|
||||
#define HAPPY_EYEBALLS_TIMEOUT 200 /* milliseconds to wait between
|
||||
ipv4/ipv6 connection attempts */
|
||||
IPv4/IPv6 connection attempts */
|
||||
|
||||
/*
|
||||
* Used to extract socket and connectdata struct for the most recent
|
||||
|
@ -1254,10 +1254,10 @@ static CURLcode ftp_state_use_port(struct connectdata *conn,
|
||||
continue;
|
||||
|
||||
if((PORT == fcmd) && sa->sa_family != AF_INET)
|
||||
/* PORT is ipv4 only */
|
||||
/* PORT is IPv4 only */
|
||||
continue;
|
||||
|
||||
switch (sa->sa_family) {
|
||||
switch(sa->sa_family) {
|
||||
case AF_INET:
|
||||
port = ntohs(sa4->sin_port);
|
||||
break;
|
||||
|
@ -110,7 +110,7 @@ CURLcode Curl_addrinfo_callback(struct connectdata *conn,
|
||||
async struct */
|
||||
conn->async.done = TRUE;
|
||||
|
||||
/* ipv4: The input hostent struct will be freed by ares when we return from
|
||||
/* IPv4: The input hostent struct will be freed by ares when we return from
|
||||
this function */
|
||||
return result;
|
||||
}
|
||||
|
@ -98,8 +98,8 @@
|
||||
* hostip.c - method-independent resolver functions and utility functions
|
||||
* hostasyn.c - functions for asynchronous name resolves
|
||||
* hostsyn.c - functions for synchronous name resolves
|
||||
* hostip4.c - ipv4-specific functions
|
||||
* hostip6.c - ipv6-specific functions
|
||||
* hostip4.c - IPv4 specific functions
|
||||
* hostip6.c - IPv6 specific functions
|
||||
*
|
||||
* The two asynchronous name resolver backends are implemented in:
|
||||
* asyn-ares.c - functions for ares-using name resolves
|
||||
|
@ -7,7 +7,7 @@
|
||||
* | (__| |_| | _ <| |___
|
||||
* \___|\___/|_| \_\_____|
|
||||
*
|
||||
* Copyright (C) 1998 - 2013, Daniel Stenberg, <daniel@haxx.se>, et al.
|
||||
* Copyright (C) 1998 - 2014, Daniel Stenberg, <daniel@haxx.se>, et al.
|
||||
*
|
||||
* This software is licensed as described in the file COPYING, which
|
||||
* you should have received as part of this distribution. The terms
|
||||
@ -92,7 +92,7 @@ int Curl_resolv_timeout(struct connectdata *conn, const char *hostname,
|
||||
|
||||
#ifdef CURLRES_IPV6
|
||||
/*
|
||||
* Curl_ipv6works() returns TRUE if ipv6 seems to work.
|
||||
* Curl_ipv6works() returns TRUE if IPv6 seems to work.
|
||||
*/
|
||||
bool Curl_ipv6works(void);
|
||||
#else
|
||||
|
@ -5,7 +5,7 @@
|
||||
* | (__| |_| | _ <| |___
|
||||
* \___|\___/|_| \_\_____|
|
||||
*
|
||||
* Copyright (C) 1998 - 2013, Daniel Stenberg, <daniel@haxx.se>, et al.
|
||||
* Copyright (C) 1998 - 2014, Daniel Stenberg, <daniel@haxx.se>, et al.
|
||||
*
|
||||
* This software is licensed as described in the file COPYING, which
|
||||
* you should have received as part of this distribution. The terms
|
||||
@ -57,9 +57,9 @@
|
||||
#include "memdebug.h"
|
||||
|
||||
/***********************************************************************
|
||||
* Only for plain-ipv4 builds
|
||||
* Only for plain IPv4 builds
|
||||
**********************************************************************/
|
||||
#ifdef CURLRES_IPV4 /* plain ipv4 code coming up */
|
||||
#ifdef CURLRES_IPV4 /* plain IPv4 code coming up */
|
||||
/*
|
||||
* Curl_ipvalid() checks what CURL_IPRESOLVE_* requirements that might've
|
||||
* been set and returns TRUE if they are OK.
|
||||
@ -67,7 +67,7 @@
|
||||
bool Curl_ipvalid(struct connectdata *conn)
|
||||
{
|
||||
if(conn->ip_version == CURL_IPRESOLVE_V6)
|
||||
/* an ipv6 address was requested and we can't get/use one */
|
||||
/* An IPv6 address was requested and we can't get/use one */
|
||||
return FALSE;
|
||||
|
||||
return TRUE; /* OK, proceed */
|
||||
@ -76,7 +76,7 @@ bool Curl_ipvalid(struct connectdata *conn)
|
||||
#ifdef CURLRES_SYNCH
|
||||
|
||||
/*
|
||||
* Curl_getaddrinfo() - the ipv4 synchronous version.
|
||||
* Curl_getaddrinfo() - the IPv4 synchronous version.
|
||||
*
|
||||
* The original code to this function was from the Dancer source code, written
|
||||
* by Bjorn Reese, it has since been patched and modified considerably.
|
||||
|
@ -5,7 +5,7 @@
|
||||
* | (__| |_| | _ <| |___
|
||||
* \___|\___/|_| \_\_____|
|
||||
*
|
||||
* Copyright (C) 1998 - 2013, Daniel Stenberg, <daniel@haxx.se>, et al.
|
||||
* Copyright (C) 1998 - 2014, Daniel Stenberg, <daniel@haxx.se>, et al.
|
||||
*
|
||||
* This software is licensed as described in the file COPYING, which
|
||||
* you should have received as part of this distribution. The terms
|
||||
@ -58,7 +58,7 @@
|
||||
#include "memdebug.h"
|
||||
|
||||
/***********************************************************************
|
||||
* Only for ipv6-enabled builds
|
||||
* Only for IPv6-enabled builds
|
||||
**********************************************************************/
|
||||
#ifdef CURLRES_IPV6
|
||||
|
||||
@ -97,7 +97,7 @@ int curl_dogetnameinfo(GETNAMEINFO_QUAL_ARG1 GETNAMEINFO_TYPE_ARG1 sa,
|
||||
#endif /* defined(CURLDEBUG) && defined(HAVE_GETNAMEINFO) */
|
||||
|
||||
/*
|
||||
* Curl_ipv6works() returns TRUE if ipv6 seems to work.
|
||||
* Curl_ipv6works() returns TRUE if IPv6 seems to work.
|
||||
*/
|
||||
bool Curl_ipv6works(void)
|
||||
{
|
||||
@ -109,7 +109,7 @@ bool Curl_ipv6works(void)
|
||||
/* probe to see if we have a working IPv6 stack */
|
||||
curl_socket_t s = socket(PF_INET6, SOCK_DGRAM, 0);
|
||||
if(s == CURL_SOCKET_BAD)
|
||||
/* an ipv6 address was requested but we can't get/use one */
|
||||
/* an IPv6 address was requested but we can't get/use one */
|
||||
ipv6_works = 0;
|
||||
else {
|
||||
ipv6_works = 1;
|
||||
@ -152,7 +152,7 @@ static void dump_addrinfo(struct connectdata *conn, const Curl_addrinfo *ai)
|
||||
#endif
|
||||
|
||||
/*
|
||||
* Curl_getaddrinfo() when built ipv6-enabled (non-threading and
|
||||
* Curl_getaddrinfo() when built IPv6-enabled (non-threading and
|
||||
* non-ares version).
|
||||
*
|
||||
* Returns name information about the given hostname and port number. If
|
||||
@ -192,7 +192,7 @@ Curl_addrinfo *Curl_getaddrinfo(struct connectdata *conn,
|
||||
}
|
||||
|
||||
if((pf != PF_INET) && !Curl_ipv6works())
|
||||
/* the stack seems to be a non-ipv6 one */
|
||||
/* The stack seems to be a non-IPv6 one */
|
||||
pf = PF_INET;
|
||||
|
||||
memset(&hints, 0, sizeof(hints));
|
||||
|
@ -289,7 +289,7 @@ data that is defined within the <reply><data></data></reply> section.
|
||||
If there's no test number found above, the HTTP test server will use the
|
||||
number following the last dot in the given hostname (made so that a CONNECT
|
||||
can still pass on test number) so that "foo.bar.123" gets treated as test case
|
||||
123. Alternatively, if an ipv6-address is provided to CONNECT, the last
|
||||
123. Alternatively, if an IPv6 address is provided to CONNECT, the last
|
||||
hexadecimal group in the address will be used as the test numer! For example
|
||||
the address "[1234::ff]" would be treated as test case 255.
|
||||
|
||||
|
@ -2529,12 +2529,12 @@ sub checksystem {
|
||||
}
|
||||
|
||||
if($has_ipv6) {
|
||||
# client has ipv6 support
|
||||
# client has IPv6 support
|
||||
|
||||
# check if the HTTP server has it!
|
||||
my @sws = `server/sws --version`;
|
||||
if($sws[0] =~ /IPv6/) {
|
||||
# HTTP server has ipv6 support!
|
||||
# HTTP server has IPv6 support!
|
||||
$http_ipv6 = 1;
|
||||
$gopher_ipv6 = 1;
|
||||
}
|
||||
@ -2542,7 +2542,7 @@ sub checksystem {
|
||||
# check if the FTP server has it!
|
||||
@sws = `server/sockfilt --version`;
|
||||
if($sws[0] =~ /IPv6/) {
|
||||
# FTP server has ipv6 support!
|
||||
# FTP server has IPv6 support!
|
||||
$ftp_ipv6 = 1;
|
||||
}
|
||||
}
|
||||
|
@ -120,7 +120,7 @@ int main(int argc, char *argv[])
|
||||
/* Check that the system has IPv6 enabled before checking the resolver */
|
||||
curl_socket_t s = socket(PF_INET6, SOCK_DGRAM, 0);
|
||||
if(s == CURL_SOCKET_BAD)
|
||||
/* an ipv6 address was requested and we can't get/use one */
|
||||
/* an IPv6 address was requested and we can't get/use one */
|
||||
rc = -1;
|
||||
else {
|
||||
sclose(s);
|
||||
|
@ -23,7 +23,7 @@
|
||||
|
||||
/* Purpose
|
||||
*
|
||||
* 1. Accept a TCP connection on a custom port (ipv4 or ipv6), or connect
|
||||
* 1. Accept a TCP connection on a custom port (IPv4 or IPv6), or connect
|
||||
* to a given (localhost) port.
|
||||
*
|
||||
* 2. Get commands on STDIN. Pass data on to the TCP stream.
|
||||
|
Loading…
Reference in New Issue
Block a user