On Wed, Aug 23, 2017 at 10:42:36PM +0200, Klemens Nanni wrote:
> Calling `iked reload' when I meant `ikectl reload' showed that iked
> happily returned 0 and and fired up another daemon.
>
> Feedback?
Second bump after two months with the diff reattached. Anyone?
diff --git a/sbin/iked/iked.c b/sbin/iked/iked.c
index 61079167c2a..51183c9b990 100644
--- a/sbin/iked/iked.c
+++ b/sbin/iked/iked.c
@@ -109,6 +109,11 @@ main(int argc, char *argv[])
usage();
}
}
+ argc -= optind;
+ argv += optind;
+
+ if (argc > 1)
+ usage();
if ((env = calloc(1, sizeof(*env))) == NULL)
fatal("calloc: env");