Modify the sources to make WARNS=6 work.

This commit is contained in:
Ed Schouten 2009-12-26 14:33:55 +00:00
parent bf792d68c7
commit af5bd8feb3
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=201022
2 changed files with 4 additions and 3 deletions

View File

@ -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

View File

@ -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;