]> git.ipfire.org Git - thirdparty/kea.git/commitdiff
[#148,!80] When run without arguments netconf,d2,ca prints out usage.
authorTomek Mrugalski <tomasz@isc.org>
Fri, 19 Oct 2018 15:54:28 +0000 (17:54 +0200)
committerFrancis Dupont <fdupont@isc.org>
Fri, 19 Oct 2018 21:35:35 +0000 (23:35 +0200)
src/lib/process/d_controller.cc

index 9e388f0d3d3c411a4ea5031550f98613085229de..b35578a0730a22fd516972939c870c9e75d51c61 100644 (file)
@@ -221,6 +221,11 @@ DControllerBase::checkConfigOnly() {
 void
 DControllerBase::parseArgs(int argc, char* argv[])
 {
+
+    if (argc == 1) {
+        isc_throw(InvalidUsage, "");
+    }
+
     // Iterate over the given command line options. If its a stock option
     // ("c" or "d") handle it here.  If its a valid custom option, then
     // invoke customOption.