summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorbluhm <bluhm@openbsd.org>2019-11-30 05:42:31 +0000
committerbluhm <bluhm@openbsd.org>2019-11-30 05:42:31 +0000
commit35f18f03b57d08dcf6e2d5f609edd9877743a7b2 (patch)
tree0165b975a3d9e1cd95a556d6c893688552a7d854
parentAdd create-vdisk command (diff)
downloadwireguard-openbsd-35f18f03b57d08dcf6e2d5f609edd9877743a7b2.tar.xz
wireguard-openbsd-35f18f03b57d08dcf6e2d5f609edd9877743a7b2.zip
ifconfig(8) did silently ignore the netmask parameter for inet6 and
interpreted only prefixlen. Also accept netmask for IPv6. This is consistent to our man page and the route(8) command. OK benno@
-rw-r--r--sbin/ifconfig/ifconfig.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/sbin/ifconfig/ifconfig.c b/sbin/ifconfig/ifconfig.c
index 2350c2d5770..0ee441181c9 100644
--- a/sbin/ifconfig/ifconfig.c
+++ b/sbin/ifconfig/ifconfig.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: ifconfig.c,v 1.415 2019/11/27 17:49:09 deraadt Exp $ */
+/* $OpenBSD: ifconfig.c,v 1.416 2019/11/30 05:42:31 bluhm Exp $ */
/* $NetBSD: ifconfig.c,v 1.40 1997/10/01 02:19:43 enami Exp $ */
/*
@@ -1302,6 +1302,7 @@ void
setifnetmask(const char *addr, int ignored)
{
afp->af_getaddr(addr, MASK);
+ explicit_prefix = 1;
}
/* ARGSUSED */