From: Nick Porter Date: Fri, 19 May 2023 07:53:21 +0000 (+0100) Subject: Allow for unlang_ctx->rules == NULL X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=317401b0dd0973b242e162c97f0ac2c9f4e193e7;p=thirdparty%2Ffreeradius-server.git Allow for unlang_ctx->rules == NULL --- diff --git a/src/lib/unlang/compile.c b/src/lib/unlang/compile.c index 1699edc7aba..1949312ef41 100644 --- a/src/lib/unlang/compile.c +++ b/src/lib/unlang/compile.c @@ -4726,7 +4726,8 @@ static unlang_t *compile_module(unlang_t *parent, unlang_compile_t *unlang_ctx, call_env_parsed_init(&single->call_env_parsed); if (call_env_parse(single->call_env_ctx, &single->call_env_parsed, single->self.name, - unlang_ctx->rules->attr.dict_def, inst->dl_inst->conf, method_env->env) < 0) { + unlang_ctx->rules ? unlang_ctx->rules->attr.dict_def : fr_dict_internal(), + inst->dl_inst->conf, method_env->env) < 0) { error: talloc_free(c); return NULL;