summaryrefslogtreecommitdiffstats
path: root/usr.sbin/arp
diff options
context:
space:
mode:
authorglebius <glebius@FreeBSD.org>2012-04-02 10:44:25 +0000
committerglebius <glebius@FreeBSD.org>2012-04-02 10:44:25 +0000
commit56216c3bc99342baf89a814301e85dffe7a62a9b (patch)
tree7628fab7fc615e1c1e98c31d02da696b16d3edf2 /usr.sbin/arp
parent0a4ce326a73bdc8b6b96ff8028c64860d1e775f1 (diff)
downloadFreeBSD-src-56216c3bc99342baf89a814301e85dffe7a62a9b.zip
FreeBSD-src-56216c3bc99342baf89a814301e85dffe7a62a9b.tar.gz
Historically arp(8) did a route lookup for the entry it is
about to add, and failed if it exist and had invalid data link type. Later on, in r201282, this check morphed to other code, but message "proxy entry exists for non 802 device" still left, and now it is printed in a case if route prefix found is equal to current address being added. In other words, when we are trying to add ARP entry for a network address. The message is absolutely unrelated and disappointing in this case. I don't see anything bad with setting ARP entries for network addresses. While useless in usual network, in a /31 RFC3021 it may be necessary. This, remove this code.
Diffstat (limited to 'usr.sbin/arp')
-rw-r--r--usr.sbin/arp/arp.c4
1 files changed, 0 insertions, 4 deletions
diff --git a/usr.sbin/arp/arp.c b/usr.sbin/arp/arp.c
index 59fbea8..9a7f91f 100644
--- a/usr.sbin/arp/arp.c
+++ b/usr.sbin/arp/arp.c
@@ -387,10 +387,6 @@ set(int argc, char **argv)
}
addr = (struct sockaddr_inarp *)(rtm + 1);
sdl = (struct sockaddr_dl *)(SA_SIZE(addr) + (char *)addr);
- if (addr->sin_addr.s_addr == dst->sin_addr.s_addr) {
- printf("set: proxy entry exists for non 802 device\n");
- return (1);
- }
if ((sdl->sdl_family != AF_LINK) ||
(rtm->rtm_flags & RTF_GATEWAY) ||
OpenPOWER on IntegriCloud