summaryrefslogtreecommitdiff
path: root/source4/lib/util_sock.c
diff options
context:
space:
mode:
authorAndrew Tridgell <tridge@samba.org>2004-11-02 03:58:27 +0000
committerGerald (Jerry) Carter <jerry@samba.org>2007-10-10 13:05:15 -0500
commit5011f901aa0140ed60a0b58e80ab0f14810ba432 (patch)
tree379ad85e8627394a47bbac5e783e0955a5a5d481 /source4/lib/util_sock.c
parent2f7d7e47e38d88655baddad4e2e0572d4c158f70 (diff)
downloadsamba-5011f901aa0140ed60a0b58e80ab0f14810ba432.tar.gz
samba-5011f901aa0140ed60a0b58e80ab0f14810ba432.tar.bz2
samba-5011f901aa0140ed60a0b58e80ab0f14810ba432.zip
r3457: s_addr is a macro on solaris, so we can't use it in structure names. arrgh.
(This used to be commit 7842b23d01c53009259a2461600bd01159cecebf)
Diffstat (limited to 'source4/lib/util_sock.c')
-rw-r--r--source4/lib/util_sock.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/source4/lib/util_sock.c b/source4/lib/util_sock.c
index dbd71b58b6..876698535b 100644
--- a/source4/lib/util_sock.c
+++ b/source4/lib/util_sock.c
@@ -170,7 +170,7 @@ ssize_t read_udp_socket(int fd, char *buf, size_t len,
}
if (from_addr) {
- from_addr->s_addr = sock.sin_addr.s_addr;
+ from_addr->addr = sock.sin_addr.s_addr;
}
if (from_port) {
*from_port = ntohs(sock.sin_port);
@@ -512,7 +512,7 @@ char *get_socket_name(TALLOC_CTX *mem_ctx, int fd, BOOL force_lookup)
addr = interpret_addr2(p);
/* Look up the remote host name. */
- if ((hp = gethostbyaddr((char *)&addr.s_addr, sizeof(addr.s_addr), AF_INET)) == 0) {
+ if ((hp = gethostbyaddr((char *)&addr.addr, sizeof(addr.addr), AF_INET)) == 0) {
DEBUG(1,("Gethostbyaddr failed for %s\n",p));
name_buf = talloc_strdup(mem_ctx, p);
} else {