summaryrefslogtreecommitdiff
path: root/lib/socket
diff options
context:
space:
mode:
authorJeremy Allison <jra@samba.org>2011-10-14 13:48:53 -0700
committerJeremy Allison <jra@samba.org>2011-10-14 13:48:53 -0700
commit744dd6bcbe7e078daac150d9e7be60c89985b510 (patch)
tree68722dcb9ec096bb8fcd4b527f8e53994c8737b7 /lib/socket
parentabe5afc580dcaaab70f136904d98fa83bfae7b6e (diff)
downloadsamba-744dd6bcbe7e078daac150d9e7be60c89985b510.tar.gz
Fix const warnings.
Diffstat (limited to 'lib/socket')
-rw-r--r--lib/socket/interfaces.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/socket/interfaces.c b/lib/socket/interfaces.c
index 9bdecb243d8..775956ba990 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;
}