From: Lennart Poettering Date: Wed, 12 Oct 2005 20:37:12 +0000 (+0000) Subject: add a (struct sockaddr*) cast to getsockname X-Git-Url: https://git.meshlink.io/?a=commitdiff_plain;h=7284ae273629e948d4aaef6d05047b31de5885ef;p=catta add a (struct sockaddr*) cast to getsockname git-svn-id: file:///home/lennart/svn/public/avahi/trunk@743 941a03a8-eaeb-0310-b9a0-b1bbd8fe43fe --- diff --git a/avahi-core/server.c b/avahi-core/server.c index 9046ec4..f23ef39 100644 --- a/avahi-core/server.c +++ b/avahi-core/server.c @@ -881,7 +881,7 @@ static int originates_from_local_legacy_unicast_socket(AvahiServer *s, const str struct sockaddr_in lsa; socklen_t l = sizeof(lsa); - if (getsockname(s->fd_legacy_unicast_ipv4, &lsa, &l) != 0) + if (getsockname(s->fd_legacy_unicast_ipv4, (struct sockaddr*) &lsa, &l) != 0) avahi_log_warn("getsockname(): %s", strerror(errno)); else return lsa.sin_port == ((const struct sockaddr_in*) sa)->sin_port; @@ -892,7 +892,7 @@ static int originates_from_local_legacy_unicast_socket(AvahiServer *s, const str struct sockaddr_in6 lsa; socklen_t l = sizeof(lsa); - if (getsockname(s->fd_legacy_unicast_ipv6, &lsa, &l) != 0) + if (getsockname(s->fd_legacy_unicast_ipv6, (struct sockaddr*) &lsa, &l) != 0) avahi_log_warn("getsockname(): %s", strerror(errno)); else return lsa.sin6_port == ((const struct sockaddr_in6*) sa)->sin6_port;