From: Alan T. DeKok Date: Thu, 12 May 2022 02:09:13 +0000 (-0400) Subject: sanity check for flags X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=e06d5d3cf6964c9e5333d00e0f39e1bb35903506;p=thirdparty%2Ffreeradius-server.git sanity check for flags the caller should't set run-time flags. --- diff --git a/src/lib/unlang/xlat_builtin.c b/src/lib/unlang/xlat_builtin.c index b02d88e7f77..b0e2dade7ad 100644 --- a/src/lib/unlang/xlat_builtin.c +++ b/src/lib/unlang/xlat_builtin.c @@ -180,7 +180,11 @@ xlat_t *xlat_register_module(TALLOC_CTX *ctx, module_inst_ctx_t const *mctx, return NULL; } - if (!flags) flags = &default_flags; + if (!flags) { + flags = &default_flags; + } else { + fr_assert(!flags->needs_resolving); + } /* * If it already exists, replace the instance.