diff options
Diffstat (limited to 'lib/libc/net/ethers.c')
-rw-r--r-- | lib/libc/net/ethers.c | 18 |
1 files changed, 2 insertions, 16 deletions
diff --git a/lib/libc/net/ethers.c b/lib/libc/net/ethers.c index 899022a6221..2c1e562245b 100644 --- a/lib/libc/net/ethers.c +++ b/lib/libc/net/ethers.c @@ -1,4 +1,4 @@ -/* $OpenBSD: ethers.c,v 1.16 2003/06/17 21:56:24 millert Exp $ */ +/* $OpenBSD: ethers.c,v 1.17 2004/02/16 19:41:12 otto Exp $ */ /* * Copyright (c) 1998 Todd C. Miller <Todd.Miller@courtesan.com> @@ -23,7 +23,7 @@ */ #if defined(LIBC_SCCS) && !defined(lint) -static char rcsid[] = "$OpenBSD: ethers.c,v 1.16 2003/06/17 21:56:24 millert Exp $"; +static char rcsid[] = "$OpenBSD: ethers.c,v 1.17 2004/02/16 19:41:12 otto Exp $"; #endif /* LIBC_SCCS and not lint */ #include <sys/types.h> @@ -54,13 +54,6 @@ ether_ntoa(e) { static char a[] = "xx:xx:xx:xx:xx:xx"; - if (e->ether_addr_octet[0] > 0xFF || e->ether_addr_octet[1] > 0xFF || - e->ether_addr_octet[2] > 0xFF || e->ether_addr_octet[3] > 0xFF || - e->ether_addr_octet[4] > 0xFF || e->ether_addr_octet[5] > 0xFF) { - errno = EINVAL; - return (NULL); - } - (void)snprintf(a, sizeof a, "%02x:%02x:%02x:%02x:%02x:%02x", e->ether_addr_octet[0], e->ether_addr_octet[1], e->ether_addr_octet[2], e->ether_addr_octet[3], @@ -119,13 +112,6 @@ ether_ntohost(hostname, e) int trylen; #endif - if (e->ether_addr_octet[0] > 0xFF || e->ether_addr_octet[1] > 0xFF || - e->ether_addr_octet[2] > 0xFF || e->ether_addr_octet[3] > 0xFF || - e->ether_addr_octet[4] > 0xFF || e->ether_addr_octet[5] > 0xFF) { - errno = EINVAL; - return (-1); - } - #ifdef YP snprintf(trybuf, sizeof trybuf, "%x:%x:%x:%x:%x:%x", e->ether_addr_octet[0], e->ether_addr_octet[1], |