From 78efd602977af45c3afdaa8face046b649842b37 Mon Sep 17 00:00:00 2001 From: Neehar Vijay Date: Sun, 20 Nov 2022 21:39:17 +0530 Subject: [PATCH] client: fix non-interactive mode in some cases Before this change, I noticed that some non-interactive commands don't work, $ iwctl version $ iwctl help while other ones do. $ iwctl station wlan0 show This seems to be a typo bug in the if clause checking for additional arguments. --- client/command.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/client/command.c b/client/command.c index dbd97703..84be680c 100644 --- a/client/command.c +++ b/client/command.c @@ -753,7 +753,7 @@ options_parsed: argv += optind; argc -= optind; - if (argc < 2) { + if (argc < 1) { interactive_mode = true; return false; }