From: Alan T. DeKok Date: Sat, 24 Aug 2024 13:08:23 +0000 (-0400) Subject: relax parser X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=57345a84690bee8527c79daafaf47ad196c5e9bc;p=thirdparty%2Ffreeradius-server.git relax parser as detail "suppress" uses bare words. --- diff --git a/src/lib/server/cf_file.c b/src/lib/server/cf_file.c index 2e89c443007..3c6716f00b2 100644 --- a/src/lib/server/cf_file.c +++ b/src/lib/server/cf_file.c @@ -2202,18 +2202,14 @@ check_for_eol: * Only unlang sections can have module references. * * We also allow bare words in edit lists, where the RHS is a list of values. + * + * @todo - detail "suppress" requires bare words :( */ - if( (parent->unlang == CF_UNLANG_ALLOW) || (parent->unlang == CF_UNLANG_EDIT)) { - parent->allow_locals = false; - value_token = T_INVALID; - op_token = T_OP_EQ; - value = NULL; - goto alloc_pair; - } - - ERROR("%s[%d]: Parse error: Unexpected bare word. There should be a '{' or operator after it", - frame->filename, frame->lineno); - return -1; + parent->allow_locals = false; + value_token = T_INVALID; + op_token = T_OP_EQ; + value = NULL; + goto alloc_pair; } /*