diff options
-rw-r--r-- | libexec/talkd/Makefile | 3 | ||||
-rw-r--r-- | libexec/talkd/process.c | 4 |
2 files changed, 4 insertions, 3 deletions
diff --git a/libexec/talkd/Makefile b/libexec/talkd/Makefile index 10f6519..4900857 100644 --- a/libexec/talkd/Makefile +++ b/libexec/talkd/Makefile @@ -6,7 +6,8 @@ SRCS= talkd.c announce.c process.c table.c print.c ttymsg.c .PATH: ${.CURDIR}/../../usr.bin/wall MAN= talkd.8 CFLAGS+=-I${.CURDIR}/../../usr.bin/wall -WFORMAT=0 + +WARNS?= 6 DPADD= ${LIBULOG} LDADD= -lulog diff --git a/libexec/talkd/process.c b/libexec/talkd/process.c index c6ec34d..d796cd5 100644 --- a/libexec/talkd/process.c +++ b/libexec/talkd/process.c @@ -155,8 +155,8 @@ do_announce(CTL_MSG *mp, CTL_RESPONSE *rp) rp->answer = result; return; } -#define satosin(sa) ((struct sockaddr_in *)(sa)) - hp = gethostbyaddr((char *)&satosin(&mp->ctl_addr)->sin_addr, +#define satosin(sa) ((struct sockaddr_in *)(void *)(sa)) + hp = gethostbyaddr(&satosin(&mp->ctl_addr)->sin_addr, sizeof (struct in_addr), AF_INET); if (hp == (struct hostent *)0) { rp->answer = MACHINE_UNKNOWN; |