summaryrefslogtreecommitdiff
path: root/usr.sbin/arp/arp.c
diff options
context:
space:
mode:
Diffstat (limited to 'usr.sbin/arp/arp.c')
-rw-r--r--usr.sbin/arp/arp.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/usr.sbin/arp/arp.c b/usr.sbin/arp/arp.c
index 1955b600586..fb7ff267997 100644
--- a/usr.sbin/arp/arp.c
+++ b/usr.sbin/arp/arp.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: arp.c,v 1.9 1997/11/21 22:42:55 deraadt Exp $ */
+/* $OpenBSD: arp.c,v 1.10 1997/11/28 05:34:41 art Exp $ */
/* $NetBSD: arp.c,v 1.12 1995/04/24 13:25:18 cgd Exp $ */
/*
@@ -215,6 +215,8 @@ set(argc, argv)
if (getinetaddr(host, &sin->sin_addr) == -1)
return (1);
ea = ether_aton(eaddr);
+ if (ea == NULL)
+ errx(1, "invalid ethernet address: %s\n", eaddr);
memcpy(LLADDR(&sdl_m), ea, sizeof (*ea));
sdl_m.sdl_alen = 6;
doing_proxy = flags = export_only = expire_time = 0;