summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTheo de Raadt <deraadt@cvs.openbsd.org>1996-12-10 15:15:40 +0000
committerTheo de Raadt <deraadt@cvs.openbsd.org>1996-12-10 15:15:40 +0000
commit0c9de56573a9a1b98dbea1d411be578d800586f9 (patch)
tree22cca26aeab26de4c4500cd5a340cdd5701258e7
parent958b36584d6a4c6f5c5a9f5cca9d9a8fb9e556a2 (diff)
warnx, from netbsd
-rw-r--r--usr.sbin/arp/arp.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/usr.sbin/arp/arp.c b/usr.sbin/arp/arp.c
index bff4cccfa95..d2c329021ec 100644
--- a/usr.sbin/arp/arp.c
+++ b/usr.sbin/arp/arp.c
@@ -508,14 +508,12 @@ getinetaddr(host, inap)
const char *host;
struct in_addr *inap;
{
- extern char *__progname; /* Program name, from crt0. */
struct hostent *hp;
if (inet_aton(host, inap) == 1)
return (0);
if ((hp = gethostbyname(host)) == NULL) {
- (void)fprintf(stderr, "%s: %s: ", __progname, host);
- herror(NULL);
+ warnx("%s: %s\n", host, hstrerror(h_errno));
return (-1);
}
(void)memcpy(inap, hp->h_addr, sizeof(*inap));