diff options
author | jan.nijtmans <nijtmans@users.sourceforge.net> | 2019-08-14 06:42:58 (GMT) |
---|---|---|
committer | jan.nijtmans <nijtmans@users.sourceforge.net> | 2019-08-14 06:42:58 (GMT) |
commit | c9376306301e578615cfee52d2121f78cb31a225 (patch) | |
tree | b80d507267bc38923d21ef904af4a227e2f4909d /compat/fake-rfc2553.c | |
parent | 343b0349d4d4b41ca86832298dead909b1ef055d (diff) | |
download | tcl-c9376306301e578615cfee52d2121f78cb31a225.zip tcl-c9376306301e578615cfee52d2121f78cb31a225.tar.gz tcl-c9376306301e578615cfee52d2121f78cb31a225.tar.bz2 |
Remove "register" keyword in various places. Also add some type-casts to help C++ compatibility.
Diffstat (limited to 'compat/fake-rfc2553.c')
-rw-r--r-- | compat/fake-rfc2553.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/compat/fake-rfc2553.c b/compat/fake-rfc2553.c index c8e69400..29e2b56 100644 --- a/compat/fake-rfc2553.c +++ b/compat/fake-rfc2553.c @@ -73,6 +73,7 @@ int fake_getnameinfo(const struct sockaddr *sa, size_t salen, char *host, struct sockaddr_in *sin = (struct sockaddr_in *)sa; struct hostent *hp; char tmpserv[16]; + (void)salen; if (sa->sa_family != AF_UNSPEC && sa->sa_family != AF_INET) return (EAI_FAMILY); @@ -153,7 +154,7 @@ addrinfo *malloc_ai(int port, u_long addr, const struct addrinfo *hints) { struct addrinfo *ai; - ai = malloc(sizeof(*ai) + sizeof(struct sockaddr_in)); + ai = (struct addrinfo *)malloc(sizeof(*ai) + sizeof(struct sockaddr_in)); if (ai == NULL) return (NULL); |