Changed names of functions in utility.c and all affected files, to make

compliant with the style guide. Everybody rebuild your tags file!
This commit is contained in:
Mark Whitley
2000-12-07 19:56:48 +00:00
parent 7b5c16ebe5
commit f57c944e09
155 changed files with 1019 additions and 1019 deletions

18
ping.c
View File

@ -1,6 +1,6 @@
/* vi: set sw=4 ts=4: */
/*
* $Id: ping.c,v 1.27 2000/12/01 02:55:13 kraai Exp $
* $Id: ping.c,v 1.28 2000/12/07 19:56:48 markw Exp $
* Mini ping implementation for busybox
*
* Copyright (C) 1999 by Randolph Chung <tausq@debian.org>
@ -202,7 +202,7 @@ static void ping(const char *host)
pingaddr.sin_family = AF_INET;
if (!(h = gethostbyname(host))) {
errorMsg("unknown host %s\n", host);
error_msg("unknown host %s\n", host);
exit(1);
}
memcpy(&pingaddr.sin_addr, h->h_addr, sizeof(pingaddr.sin_addr));
@ -219,7 +219,7 @@ static void ping(const char *host)
if (c < 0 || c != sizeof(packet)) {
if (c < 0)
perror("ping: sendto");
errorMsg("write incomplete\n");
error_msg("write incomplete\n");
exit(1);
}
@ -325,9 +325,9 @@ static void sendping(int junk)
(struct sockaddr *) &pingaddr, sizeof(struct sockaddr_in));
if (i < 0)
fatalError("sendto: %s\n", strerror(errno));
error_msg_and_die("sendto: %s\n", strerror(errno));
else if ((size_t)i != sizeof(packet))
fatalError("ping wrote %d chars; %d expected\n", i,
error_msg_and_die("ping wrote %d chars; %d expected\n", i,
(int)sizeof(packet));
signal(SIGALRM, sendping);
@ -422,7 +422,7 @@ static void unpack(char *buf, int sz, struct sockaddr_in *from)
printf("\n");
} else
if (icmppkt->icmp_type != ICMP_ECHO)
errorMsg("Warning: Got ICMP %d (%s)\n",
error_msg("Warning: Got ICMP %d (%s)\n",
icmppkt->icmp_type, icmp_type_name (icmppkt->icmp_type));
}
@ -440,7 +440,7 @@ static void ping(const char *host)
if ((pingsock = socket(AF_INET, SOCK_RAW,
(proto ? proto->p_proto : 1))) < 0) { /* 1 == ICMP */
if (errno == EPERM) {
errorMsg("permission denied. (are you root?)\n");
error_msg("permission denied. (are you root?)\n");
} else {
perror("ping: creating a raw socket");
}
@ -454,12 +454,12 @@ static void ping(const char *host)
pingaddr.sin_family = AF_INET;
if (!(h = gethostbyname(host))) {
errorMsg("unknown host %s\n", host);
error_msg("unknown host %s\n", host);
exit(1);
}
if (h->h_addrtype != AF_INET) {
errorMsg("unknown address type; only AF_INET is currently supported.\n");
error_msg("unknown address type; only AF_INET is currently supported.\n");
exit(1);
}