diff options
author | Jeremy Allison <jra@samba.org> | 2011-10-14 13:48:53 -0700 |
---|---|---|
committer | Jeremy Allison <jra@samba.org> | 2011-10-14 13:48:53 -0700 |
commit | 744dd6bcbe7e078daac150d9e7be60c89985b510 (patch) | |
tree | 68722dcb9ec096bb8fcd4b527f8e53994c8737b7 | |
parent | abe5afc580dcaaab70f136904d98fa83bfae7b6e (diff) | |
download | samba-744dd6bcbe7e078daac150d9e7be60c89985b510.tar.gz samba-744dd6bcbe7e078daac150d9e7be60c89985b510.tar.bz2 samba-744dd6bcbe7e078daac150d9e7be60c89985b510.zip |
Fix const warnings.
-rw-r--r-- | lib/socket/interfaces.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/socket/interfaces.c b/lib/socket/interfaces.c index 9bdecb243d..775956ba99 100644 --- a/lib/socket/interfaces.c +++ b/lib/socket/interfaces.c @@ -77,7 +77,7 @@ static void make_bcast_or_net(struct sockaddr_storage *pss_out, bool make_bcast_p) { unsigned int i = 0, len = 0; - char *pmask = NULL; + const char *pmask = NULL; char *p = NULL; *pss_out = *pss_in; @@ -85,13 +85,13 @@ static void make_bcast_or_net(struct sockaddr_storage *pss_out, #if defined(HAVE_IPV6) if (pss_in->ss_family == AF_INET6) { p = (char *)&((struct sockaddr_in6 *)pss_out)->sin6_addr; - pmask = discard_const_p(char, &((struct sockaddr_in6 *)nmask)->sin6_addr); + pmask = (const char *)&((const struct sockaddr_in6 *)nmask)->sin6_addr; len = 16; } #endif if (pss_in->ss_family == AF_INET) { p = (char *)&((struct sockaddr_in *)pss_out)->sin_addr; - pmask = discard_const_p(char, &((struct sockaddr_in *)nmask)->sin_addr); + pmask = (const char *)&((const struct sockaddr_in *)nmask)->sin_addr; len = 4; } |