summaryrefslogtreecommitdiff
path: root/sbin/pfctl/pfctl_parser.c
diff options
context:
space:
mode:
authorkn <kn@cvs.openbsd.org>2018-09-11 10:42:11 +0000
committerkn <kn@cvs.openbsd.org>2018-09-11 10:42:11 +0000
commitb1339549a607d44f8a82a2283221b872c34cd3e0 (patch)
tree9238139bc6b876ad64813bb987a6dcf95d3b5918 /sbin/pfctl/pfctl_parser.c
parent7a22397806b0a36170bb0e7eb91fffa33648998c (diff)
Fix netmask regression in get_dynnode()
I introduced this error with r1.330 while removing the af parameter from unmask(). `pass inet from (lo0)/24' would result in `pass inet from (lo0)', sorry.
Diffstat (limited to 'sbin/pfctl/pfctl_parser.c')
-rw-r--r--sbin/pfctl/pfctl_parser.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/sbin/pfctl/pfctl_parser.c b/sbin/pfctl/pfctl_parser.c
index 089069dc72e..ddd1b9ca60b 100644
--- a/sbin/pfctl/pfctl_parser.c
+++ b/sbin/pfctl/pfctl_parser.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: pfctl_parser.c,v 1.335 2018/09/11 09:02:27 kn Exp $ */
+/* $OpenBSD: pfctl_parser.c,v 1.336 2018/09/11 10:42:10 kn Exp $ */
/*
* Copyright (c) 2001 Daniel Hartmeier
@@ -1335,7 +1335,7 @@ gen_dynnode(struct node_host *h, sa_family_t af)
/* fix up netmask */
m = &n->addr.v.a.mask;
- if (af == AF_INET && unmask(m))
+ if (af == AF_INET && unmask(m) > 32)
set_ipmask(n, 32);
return (n);