summaryrefslogtreecommitdiffstats
path: root/usr.sbin/ppp/filter.c
diff options
context:
space:
mode:
authorbrian <brian@FreeBSD.org>1997-07-27 23:26:23 +0000
committerbrian <brian@FreeBSD.org>1997-07-27 23:26:23 +0000
commit789c3c7d2933819fc67e6c20ae4cc544d5183247 (patch)
tree957734b65f4a1a63bec19236862880811b01f92a /usr.sbin/ppp/filter.c
parent985e44c31d16943ee0fe732c5a5767f1ed9986d6 (diff)
downloadFreeBSD-src-789c3c7d2933819fc67e6c20ae4cc544d5183247.zip
FreeBSD-src-789c3c7d2933819fc67e6c20ae4cc544d5183247.tar.gz
Count the "proto" arg after a single address,
Check correctly for "deny" packets. Submitted by: Dave Bodenstab <imdave@mcs.net>
Diffstat (limited to 'usr.sbin/ppp/filter.c')
-rw-r--r--usr.sbin/ppp/filter.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/usr.sbin/ppp/filter.c b/usr.sbin/ppp/filter.c
index 60e0506..375df1d 100644
--- a/usr.sbin/ppp/filter.c
+++ b/usr.sbin/ppp/filter.c
@@ -17,7 +17,7 @@
* IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED
* WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE.
*
- * $Id: filter.c,v 1.10 1997/06/09 03:27:19 brian Exp $
+ * $Id: filter.c,v 1.11 1997/06/28 01:34:03 brian Exp $
*
* TODO: Shoud send ICMP error message when we discard packets.
*/
@@ -308,7 +308,7 @@ struct filterent *ofp;
argc--; argv++;
- if (ofp->action == A_DENY) {
+ if (fp->action == A_DENY) {
if (STREQ(*argv, "host")) {
fp->action |= A_UHOST;
argc--; argv++;
@@ -331,6 +331,8 @@ struct filterent *ofp;
if (proto) {
argc--; argv++;
}
+ } else {
+ argc--; argv++;
}
} else {
LogPrintf(LogWARN, "Parse: Address/protocol expected.\n");
OpenPOWER on IntegriCloud