diff options
author | 2006-10-06 16:27:49 +0000 | |
---|---|---|
committer | 2006-10-06 16:27:49 +0000 | |
commit | f644f0cc2f7d11c483afefe673409e02c5add26d (patch) | |
tree | 4b2f2af26c4b3bae4cd5627ae13ded6a014b093d | |
parent | these fixes got lost somehow; (diff) | |
download | wireguard-openbsd-f644f0cc2f7d11c483afefe673409e02c5add26d.tar.xz wireguard-openbsd-f644f0cc2f7d11c483afefe673409e02c5add26d.zip |
Print out 'no state' when the rule is not stateful.
-rw-r--r-- | sbin/pfctl/pfctl_parser.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/sbin/pfctl/pfctl_parser.c b/sbin/pfctl/pfctl_parser.c index c009f99a4c5..0ef6d90d25b 100644 --- a/sbin/pfctl/pfctl_parser.c +++ b/sbin/pfctl/pfctl_parser.c @@ -1,4 +1,4 @@ -/* $OpenBSD: pfctl_parser.c,v 1.227 2006/08/08 20:05:54 dhartmei Exp $ */ +/* $OpenBSD: pfctl_parser.c,v 1.228 2006/10/06 16:27:49 mcbride Exp $ */ /* * Copyright (c) 2001 Daniel Hartmeier @@ -818,7 +818,9 @@ print_rule(struct pf_rule *r, const char *anchor_call, int verbose) } if (r->tos) printf(" tos 0x%2.2x", r->tos); - if (r->keep_state == PF_STATE_NORMAL) + if (!r->keep_state) + printf(" no state"); + else if (r->keep_state == PF_STATE_NORMAL) printf(" keep state"); else if (r->keep_state == PF_STATE_MODULATE) printf(" modulate state"); |