diff options
| author | Cy Schubert <cy@FreeBSD.org> | 2017-01-25 20:41:16 +0000 |
|---|---|---|
| committer | Cy Schubert <cy@FreeBSD.org> | 2017-01-25 20:41:16 +0000 |
| commit | d780a32bc50de8dc50af2a1fead54fca610a0dd6 (patch) | |
| tree | d429a453f5dd6145c1fd1c9cd77092496affb722 /contrib/ipfilter | |
| parent | f27ac8e297becff0ce9f8d18535b270b2d16df7e (diff) | |
Notes
Diffstat (limited to 'contrib/ipfilter')
| -rw-r--r-- | contrib/ipfilter/tools/ipf.c | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/contrib/ipfilter/tools/ipf.c b/contrib/ipfilter/tools/ipf.c index 901728b5cc7c4..a3c0b2bff04b8 100644 --- a/contrib/ipfilter/tools/ipf.c +++ b/contrib/ipfilter/tools/ipf.c @@ -410,12 +410,16 @@ static void flushfilter(arg, filter) return; } - if (strchr(arg, 'i') || strchr(arg, 'I')) + else if (strchr(arg, 'i') || strchr(arg, 'I')) fl = FR_INQUE; - if (strchr(arg, 'o') || strchr(arg, 'O')) + else if (strchr(arg, 'o') || strchr(arg, 'O')) fl = FR_OUTQUE; - if (strchr(arg, 'a') || strchr(arg, 'A')) + else if (strchr(arg, 'a') || strchr(arg, 'A')) fl = FR_OUTQUE|FR_INQUE; + else { + fprintf(stderr, "Incorrect flush argument: %s\n", arg); + usage(); + } if (opts & OPT_INACTIVE) fl |= FR_INACTIVE; rem = fl; |
