From 39ea0df38ffc44a8d78a5524f50d22b25cd78101 Mon Sep 17 00:00:00 2001 From: Valentine Krasnobaeva Date: Tue, 19 Nov 2024 10:47:38 +0100 Subject: [PATCH] MINOR: cfgparse-global: parse options to allow non std keywords in discovery mode 'Program' section is considered as deprecated now, see the commit 581c8a27d98c ("MEDIUM: mworker: depreciate the 'program' section"). So, the 'program' section parser emits a warning every time since this commit, if its section is presented. This makes impossible to launch the process in zero-warning mode. After master-worker refactoring only the master process parses the 'program' section. So, at first, in order to be able to start in zero-warning mode, we need to parse in master process option, which allows deprecated keywords. Thus, let's set in this commit KWF_DISCOVERY flag to cfg_parse_global_non_std_directives parser, which parses 'expose-deprecated-directives' and 'expose-deprecated-directives' options. --- src/cfgparse-global.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/cfgparse-global.c b/src/cfgparse-global.c index b8369c821..c0056458a 100644 --- a/src/cfgparse-global.c +++ b/src/cfgparse-global.c @@ -1633,7 +1633,7 @@ static struct cfg_kw_list cfg_kws = {ILH, { { CFG_GLOBAL, "noevports", cfg_parse_global_disable_poller, KWF_DISCOVERY }, { CFG_GLOBAL, "nopoll", cfg_parse_global_disable_poller, KWF_DISCOVERY }, { CFG_GLOBAL, "pidfile", cfg_parse_global_pidfile, KWF_DISCOVERY }, - { CFG_GLOBAL, "expose-deprecated-directives", cfg_parse_global_non_std_directives }, + { CFG_GLOBAL, "expose-deprecated-directives", cfg_parse_global_non_std_directives, KWF_DISCOVERY }, { CFG_GLOBAL, "expose-experimental-directives", cfg_parse_global_non_std_directives }, { CFG_GLOBAL, "tune.runqueue-depth", cfg_parse_global_tune_opts }, { CFG_GLOBAL, "tune.maxpollevents", cfg_parse_global_tune_opts },