mirror of
https://github.com/moparisthebest/curl
synced 2025-01-11 14:08:07 -05:00
connect: silence sign-compare warning
With MinGW-w64 using WinSock, `curl_socklen_t` is signed, while the result of `sizeof` is unsigned. Closes https://github.com/curl/curl/pull/4483
This commit is contained in:
parent
07e987840c
commit
be16d8d994
@ -665,7 +665,7 @@ bool Curl_addr2string(struct sockaddr *sa, curl_socklen_t salen,
|
||||
#endif
|
||||
#if defined(HAVE_SYS_UN_H) && defined(AF_UNIX)
|
||||
case AF_UNIX:
|
||||
if(salen > sizeof(sa_family_t)) {
|
||||
if(salen > (curl_socklen_t)sizeof(sa_family_t)) {
|
||||
su = (struct sockaddr_un*)sa;
|
||||
msnprintf(addr, MAX_IPADR_LEN, "%s", su->sun_path);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user