From c1372a52c89860cffadec61c5da4d9af02b957ef Mon Sep 17 00:00:00 2001 From: Cedric Roux Date: Thu, 5 Jun 2025 10:13:09 +0200 Subject: [PATCH] bugfix: don't print '.' if no prefix It's confusing to read "Section ".rlc" not allowed" when it should be "Section "rlc" not allowed". --- openair2/GNB_APP/gnb_config.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/openair2/GNB_APP/gnb_config.c b/openair2/GNB_APP/gnb_config.c index e1c04fa3f4..64f6bc8421 100644 --- a/openair2/GNB_APP/gnb_config.c +++ b/openair2/GNB_APP/gnb_config.c @@ -846,7 +846,11 @@ static void verify_section_notset(configmodule_interface_t *cfg, char *aprefix, paramlist_def_t pl = {0}; strncpy(pl.listname, secname, sizeof(pl.listname) - 1); config_getlist(cfg, &pl, NULL, 0, aprefix); - AssertFatal(pl.numelt == 0, "Section \"%s.%s\" not allowed in this config, please remove it\n", aprefix ? aprefix : "", secname); + AssertFatal(pl.numelt == 0, + "Section \"%s%s%s\" not allowed in this config, please remove it\n", + aprefix ? aprefix : "", + aprefix ? "." : "", + secname); } void RCconfig_verify(configmodule_interface_t *cfg, ngran_node_t node_type) {