mirror of
https://github.com/curl/curl.git
synced 2025-02-11 14:50:40 +08:00
finally fixed the 'ret' compiler warning
This commit is contained in:
parent
f2e6d235f2
commit
d9f39cc99b
@ -123,7 +123,6 @@ struct hostent *Curl_gethost(struct UrlData *data,
|
|||||||
int ret; /* this variable is unused on several platforms but used on some */
|
int ret; /* this variable is unused on several platforms but used on some */
|
||||||
|
|
||||||
#define CURL_NAMELOOKUP_SIZE 9000
|
#define CURL_NAMELOOKUP_SIZE 9000
|
||||||
|
|
||||||
/* Allocate enough memory to hold the full name information structs and
|
/* Allocate enough memory to hold the full name information structs and
|
||||||
* everything. OSF1 is known to require at least 8872 bytes. The buffer
|
* everything. OSF1 is known to require at least 8872 bytes. The buffer
|
||||||
* required for storing all possible aliases and IP numbers is according to
|
* required for storing all possible aliases and IP numbers is according to
|
||||||
@ -133,6 +132,8 @@ struct hostent *Curl_gethost(struct UrlData *data,
|
|||||||
return NULL; /* major failure */
|
return NULL; /* major failure */
|
||||||
*bufp = buf;
|
*bufp = buf;
|
||||||
|
|
||||||
|
ret = 0; /* to prevent the compiler warning */
|
||||||
|
|
||||||
if ( (in=inet_addr(hostname)) != INADDR_NONE ) {
|
if ( (in=inet_addr(hostname)) != INADDR_NONE ) {
|
||||||
struct in_addr *addrentry;
|
struct in_addr *addrentry;
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user