From: Matthijs Mekking Date: Tue, 8 Dec 2020 10:47:57 +0000 (+0100) Subject: Log experimental options X-Git-Tag: v9.17.10~31^2~8 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=6e2597b55a794e99cc5f794eb24333b9067afe0f;p=thirdparty%2Fbind9.git Log experimental options Log a warning for the 'experimental' clause flag similar to the 'deprecated' flag. --- diff --git a/lib/isccfg/parser.c b/lib/isccfg/parser.c index f4d9ba815ad..9fd049553f7 100644 --- a/lib/isccfg/parser.c +++ b/lib/isccfg/parser.c @@ -2448,6 +2448,13 @@ cfg_parse_mapbody(cfg_parser_t *pctx, const cfg_type_t *type, cfg_obj_t **ret) { clause->name); CHECK(ISC_R_FAILURE); } + if ((clause->flags & CFG_CLAUSEFLAG_NOTCONFIGURED) != 0) { + cfg_parser_error(pctx, 0, + "option '%s' was not " + "enabled at compile time", + clause->name); + CHECK(ISC_R_FAILURE); + } /* Issue warnings if appropriate */ if ((pctx->flags & CFG_PCTX_NODEPRECATED) == 0 && @@ -2462,13 +2469,11 @@ cfg_parse_mapbody(cfg_parser_t *pctx, const cfg_type_t *type, cfg_obj_t **ret) { "should be removed ", clause->name); } - - if ((clause->flags & CFG_CLAUSEFLAG_NOTCONFIGURED) != 0) { - cfg_parser_error(pctx, 0, - "option '%s' was not " - "enabled at compile time", - clause->name); - CHECK(ISC_R_FAILURE); + if ((clause->flags & CFG_CLAUSEFLAG_EXPERIMENTAL) != 0) { + cfg_parser_warning(pctx, 0, + "option '%s' is experimental and " + "subject to change in the future", + clause->name); } /* See if the clause already has a value; if not create one. */