aboutsummaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
Diffstat (limited to 'lib')
-rw-r--r--lib/ftp.c4
-rw-r--r--lib/hostip.h2
-rw-r--r--lib/hostip6.c4
3 files changed, 5 insertions, 5 deletions
diff --git a/lib/ftp.c b/lib/ftp.c
index 49dd5ae4f..6c35ce215 100644
--- a/lib/ftp.c
+++ b/lib/ftp.c
@@ -812,7 +812,7 @@ static CURLcode ftp_state_use_port(struct connectdata *conn,
return CURLE_FTP_PORT_FAILED;
}
- rc = getnameinfo((struct sockaddr *)&ss, (size_t)sslen, hbuf, sizeof(hbuf), NULL,
+ rc = getnameinfo((struct sockaddr *)&ss, sslen, hbuf, sizeof(hbuf), NULL,
0, NIFLAGS);
if(rc) {
failf(data, "getnameinfo() returned %d\n", rc);
@@ -921,7 +921,7 @@ static CURLcode ftp_state_use_port(struct connectdata *conn,
if (EPRT == fcmd) {
if (eprtaf < 0)
continue;
- if (getnameinfo((struct sockaddr *)&ss, (size_t)sslen,
+ if (getnameinfo((struct sockaddr *)&ss, sslen,
portmsgbuf, sizeof(portmsgbuf), tmp, sizeof(tmp),
NIFLAGS))
continue;
diff --git a/lib/hostip.h b/lib/hostip.h
index f9be23c22..3baf8284b 100644
--- a/lib/hostip.h
+++ b/lib/hostip.h
@@ -191,7 +191,7 @@ int curl_dogetaddrinfo(char *hostname, char *service,
struct addrinfo *hints,
struct addrinfo **result,
int line, const char *source);
-int curl_dogetnameinfo(const struct sockaddr *sa, size_t salen,
+int curl_dogetnameinfo(const struct sockaddr *sa, socklen_t salen,
char *host, size_t hostlen,
char *serv, size_t servlen, int flags,
int line, const char *source);
diff --git a/lib/hostip6.c b/lib/hostip6.c
index edfbd54f4..04ebaedee 100644
--- a/lib/hostip6.c
+++ b/lib/hostip6.c
@@ -138,12 +138,12 @@ int curl_dogetaddrinfo(char *hostname, char *service,
return res;
}
-int curl_dogetnameinfo(const struct sockaddr *sa, size_t salen,
+int curl_dogetnameinfo(const struct sockaddr *sa, socklen_t salen,
char *host, size_t hostlen,
char *serv, size_t servlen, int flags,
int line, const char *source)
{
- int res = (getnameinfo)(sa, salen, host, hostlen, serv, servlen, flags);
+ int res=(getnameinfo)(sa, salen, host, hostlen, serv, servlen, flags);
if(0 == res) {
/* success */
if(logfile)