alertif_too_many_args(0, file, linenum, args, &err_code);
goto out;
}
+
+ if (global.mode & MODE_DISCOVERY)
+ goto discovery_kw;
+
else if (strcmp(args[0], "limited-quic") == 0) {
if (alertif_too_many_args(0, file, linenum, args, &err_code))
goto out;
const char *best;
int index;
int rc;
-
+discovery_kw:
list_for_each_entry(kwl, &cfg_keywords.list, list) {
for (index = 0; kwl->kw[index].kw != NULL; index++) {
if (kwl->kw[index].section != CFG_GLOBAL)
continue;
if (strcmp(kwl->kw[index].kw, args[0]) == 0) {
+
+ /* in MODE_DISCOVERY we read only the keywords, which contains the appropiate flag */
+ if ((global.mode & MODE_DISCOVERY) && ((kwl->kw[index].flags & KWF_DISCOVERY) == 0 ))
+ goto out;
+
if (check_kw_experimental(&kwl->kw[index], file, linenum, &errmsg)) {
ha_alert("%s\n", errmsg);
err_code |= ERR_ALERT | ERR_FATAL;
}
}
+ if (global.mode & MODE_DISCOVERY)
+ goto out;
+
best = cfg_find_best_match(args[0], &cfg_keywords.list, CFG_GLOBAL, common_kw_list);
if (best)
ha_alert("parsing [%s:%d] : unknown keyword '%s' in '%s' section; did you mean '%s' maybe ?\n", file, linenum, args[0], cursection, best);