Fix an off-by-one error and correct the man page WRT clearing
filters. Submitted by: Peter Jeremy <peter.jeremy@alcatel.com.au> PR: 12437
This commit is contained in:
parent
51f80ae148
commit
b4d797e707
@ -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.29 1999/05/31 23:57:36 brian Exp $
|
||||
* $Id: filter.c,v 1.30 1999/06/23 16:48:21 brian Exp $
|
||||
*
|
||||
* TODO: Shoud send ICMP error message when we discard packets.
|
||||
*/
|
||||
@ -306,7 +306,7 @@ Parse(struct ipcp *ipcp, int argc, char const *const *argv,
|
||||
struct filterent filterdata;
|
||||
|
||||
val = strtol(*argv, &wp, 0);
|
||||
if (*argv == wp || val > MAXFILTERS) {
|
||||
if (*argv == wp || val >= MAXFILTERS) {
|
||||
log_Printf(LogWARN, "Parse: invalid filter number.\n");
|
||||
return (0);
|
||||
}
|
||||
|
@ -1,4 +1,4 @@
|
||||
.\" $Id: ppp.8,v 1.177 1999/06/23 16:48:24 brian Exp $
|
||||
.\" $Id: ppp.8,v 1.178 1999/07/17 10:33:57 brian Exp $
|
||||
.Dd 20 September 1995
|
||||
.nr XX \w'\fC00'
|
||||
.Os FreeBSD
|
||||
@ -1424,7 +1424,7 @@ or
|
||||
is a numeric value between
|
||||
.Sq 0
|
||||
and
|
||||
.Sq 19
|
||||
.Sq 39
|
||||
specifying the rule number. Rules are specified in numeric order according to
|
||||
.Ar rule-no ,
|
||||
but only if rule
|
||||
@ -1438,6 +1438,10 @@ or
|
||||
.Sq deny .
|
||||
If a given packet
|
||||
matches the rule, the associated action is taken immediately.
|
||||
.Ar Action
|
||||
can also be specified as
|
||||
.Sq clear
|
||||
to clear the action associated with that particular rule.
|
||||
.It
|
||||
.Op Ar src_addr Ns Op / Ns Ar width
|
||||
and
|
||||
|
@ -1,4 +1,4 @@
|
||||
.\" $Id: ppp.8,v 1.177 1999/06/23 16:48:24 brian Exp $
|
||||
.\" $Id: ppp.8,v 1.178 1999/07/17 10:33:57 brian Exp $
|
||||
.Dd 20 September 1995
|
||||
.nr XX \w'\fC00'
|
||||
.Os FreeBSD
|
||||
@ -1424,7 +1424,7 @@ or
|
||||
is a numeric value between
|
||||
.Sq 0
|
||||
and
|
||||
.Sq 19
|
||||
.Sq 39
|
||||
specifying the rule number. Rules are specified in numeric order according to
|
||||
.Ar rule-no ,
|
||||
but only if rule
|
||||
@ -1438,6 +1438,10 @@ or
|
||||
.Sq deny .
|
||||
If a given packet
|
||||
matches the rule, the associated action is taken immediately.
|
||||
.Ar Action
|
||||
can also be specified as
|
||||
.Sq clear
|
||||
to clear the action associated with that particular rule.
|
||||
.It
|
||||
.Op Ar src_addr Ns Op / Ns Ar width
|
||||
and
|
||||
|
Loading…
Reference in New Issue
Block a user