From 6639982f82d6bff5e614d484aa03d1fe9780052f Mon Sep 17 00:00:00 2001 From: Matthias Gatto Date: Thu, 13 Jun 2024 16:46:48 +0200 Subject: [PATCH] oapi-cli: fix multiples --set-var Signed-off-by: Matthias Gatto --- cognac_gen.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cognac_gen.sh b/cognac_gen.sh index fcc7606..614240f 100755 --- a/cognac_gen.sh +++ b/cognac_gen.sh @@ -395,7 +395,7 @@ EOF JSON_C_TO_STRING_PRETTY | JSON_C_TO_STRING_NOSLASHESCAPE | color_flag)); } - if (i + 1 < ac && !strcmp(av[i + 1], "--set-var")) { + while (i + 1 < ac && !strcmp(av[i + 1], "--set-var")) { ++i; TRY(i + 1 >= ac, "--set-var require an argument"); if (!jobj)