aboutsummaryrefslogtreecommitdiff
path: root/contrib/ipfilter/tools
diff options
context:
space:
mode:
authorCy Schubert <cy@FreeBSD.org>2017-06-11 03:56:13 +0000
committerCy Schubert <cy@FreeBSD.org>2017-06-11 03:56:13 +0000
commit0fc43621ced5b06e7874df8e1700e2f3039c00ed (patch)
tree1108a2375551c690a810f25deb8c9d1ce3e62a65 /contrib/ipfilter/tools
parenta8f3fd8253d77c44102c6fac7ce7bcbc3722fcc0 (diff)
downloadsrc-0fc43621ced5b06e7874df8e1700e2f3039c00ed.tar.gz
src-0fc43621ced5b06e7874df8e1700e2f3039c00ed.zip
Identify command line syntax errors in poolflush() (ippool -F).
Notes
Notes: svn path=/head/; revision=319820
Diffstat (limited to 'contrib/ipfilter/tools')
-rw-r--r--contrib/ipfilter/tools/ippool.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/contrib/ipfilter/tools/ippool.c b/contrib/ipfilter/tools/ippool.c
index 18bd603fac8b..d043d0179e0b 100644
--- a/contrib/ipfilter/tools/ippool.c
+++ b/contrib/ipfilter/tools/ippool.c
@@ -557,8 +557,14 @@ poolflush(argc, argv)
case 'v' :
opts |= OPT_VERBOSE;
break;
+ default :
+ usage(argv[0]);
+ break; /* keep compiler happy */
}
+ if (argc - 1 - optind > 0)
+ usage(argv[0]);
+
if (opts & OPT_DEBUG)
fprintf(stderr, "poolflush: opts = %#x\n", opts);