From 4455b375489c0a0e8b040b4e9138869d9c013182 Mon Sep 17 00:00:00 2001 From: Romain Beurdouche Date: Thu, 2 May 2024 11:10:56 +0200 Subject: [PATCH] fix(nr_ulsim): fix cmdline configmodule for nr_ulsim --- openair1/SIMULATION/NR_PHY/ulsim.c | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/openair1/SIMULATION/NR_PHY/ulsim.c b/openair1/SIMULATION/NR_PHY/ulsim.c index 90f23c695c..e363b0c47d 100644 --- a/openair1/SIMULATION/NR_PHY/ulsim.c +++ b/openair1/SIMULATION/NR_PHY/ulsim.c @@ -223,7 +223,13 @@ int main(int argc, char *argv[]) /* initialize the sin-cos table */ InitSinLUT(); - while ((c = getopt(argc, argv, "a:b:c:d:ef:g:h:i:k:m:n:op:q:r:s:t:u:v:w:y:z:C:F:G:H:I:M:N:PR:S:T:U:L:ZW:E:X:")) != -1) { + while ((c = getopt(argc, argv, "--:a:b:c:d:ef:g:h:i:k:m:n:op:q:r:s:t:u:v:w:y:z:C:F:G:H:I:M:N:PR:S:T:U:L:ZW:E:X:")) != -1) { + + /* ignore long options starting with '--' and their arguments that are handled by configmodule */ + /* with this opstring getopt returns 1 for non-option arguments, refer to 'man 3 getopt' */ + if (c == 1 || c == '-') + continue; + printf("handling optarg %c\n",c); switch (c) {