BUG/MINOR: cfgparse-global: clean common_kw_list

This patch fixes commits 118ac11ce
("MINOR: cfgparse-global: move mode's keywords in cfg_kw_list") and 83ff4db18
(MINOR: cfgparse-global: move no<poller_name> in cfg_kw_list).

'common_kw_list' serves to show the best-match keyword in cfg_parse_global(), if
the given keyword was not parsed in "if..else if.." cases. cfg_parse_global()
is still used as a parser for some keywords from the global section.

Mode-specific and no<poller_name> keywords now have their own parsers. They no
longer take place in the "if..else if.." from cfg_parse_global() and they are
registered in the 'cfg_kws' list. So, there is no longer need to duplicate
them in the 'common_kw_list'. Otherwise, they will be shown twice in parser
error message.
This commit is contained in:
Valentine Krasnobaeva 2024-08-14 15:00:05 +02:00 committed by William Lallemand
parent 4291d10b44
commit 74bc6f3d66

View File

@ -31,10 +31,9 @@ int cluster_secret_isset;
* registered anywhere. They are used as suggestions for mistyped words.
*/
static const char *common_kw_list[] = {
"global", "daemon", "master-worker", "noepoll", "nokqueue",
"noevports", "nopoll", "busy-polling", "set-dumpable",
"global", "busy-polling", "set-dumpable",
"insecure-fork-wanted", "insecure-setuid-wanted", "nosplice",
"nogetaddrinfo", "noreuseport", "quiet", "zero-warning",
"nogetaddrinfo", "noreuseport",
"tune.runqueue-depth", "tune.maxpollevents", "tune.maxaccept",
"tune.recv_enough", "tune.bufsize", "tune.maxrewrite",
"tune.idletimer", "tune.rcvbuf.client", "tune.rcvbuf.server",