mirror of
https://github.com/JGRennison/OpenTTD-patches.git
synced 2024-11-16 00:12:51 +00:00
(svn r24571) -Fix: do not cast away const
This commit is contained in:
parent
95866a7a75
commit
a92f7ec90e
@ -57,7 +57,7 @@ static inline int OTTDgetnameinfo(const struct sockaddr *sa, socklen_t salen, ch
|
|||||||
|
|
||||||
if (getnameinfo != NULL) return getnameinfo(sa, salen, host, hostlen, serv, servlen, flags);
|
if (getnameinfo != NULL) return getnameinfo(sa, salen, host, hostlen, serv, servlen, flags);
|
||||||
|
|
||||||
strncpy(host, inet_ntoa(((struct sockaddr_in *)sa)->sin_addr), hostlen);
|
strncpy(host, inet_ntoa(((const struct sockaddr_in *)sa)->sin_addr), hostlen);
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
#define getnameinfo OTTDgetnameinfo
|
#define getnameinfo OTTDgetnameinfo
|
||||||
|
Loading…
Reference in New Issue
Block a user