* Replace bzero with memset and bcopy with memcpy

svn path=/trunk/; revision=11763
This commit is contained in:
Casper Hornstrup 2004-11-21 20:10:22 +00:00
parent 3adacc20ec
commit 98e47a5b69

View file

@ -116,14 +116,14 @@ int main(int argc, char **argv)
leave(1);
}
bzero(/*(caddr_t)*/&sin, sizeof (sin));
memset(/*(caddr_t)*/&sin, 0, sizeof(sin));
sin.sin_family = hp->h_addrtype;
if (bind(s, (struct sockaddr *)&sin, sizeof(sin)) < 0) {
perror("whois: bind");
leave(1);
}
bcopy(hp->h_addr, (char *)&sin.sin_addr, hp->h_length);
memcpy((char *)&sin.sin_addr, hp->h_addr, hp->h_length);
sp = getservbyname("whois", "tcp");
if (sp == NULL) {
(void)fprintf(stderr, "whois: whois/tcp: unknown service\n");