From: Nick Porter Date: Mon, 20 Feb 2023 10:51:52 +0000 (+0000) Subject: Use talloc_get_type_abort_const() for const variable X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=f61575c3f511f08cd3e04a63813008639362158d;p=thirdparty%2Ffreeradius-server.git Use talloc_get_type_abort_const() for const variable --- diff --git a/src/lib/unlang/xlat_alloc.c b/src/lib/unlang/xlat_alloc.c index 642f4e1f07a..a5a54a9312e 100644 --- a/src/lib/unlang/xlat_alloc.c +++ b/src/lib/unlang/xlat_alloc.c @@ -258,7 +258,7 @@ static int _xlat_copy_internal(NDEBUG_LOCATION_ARGS TALLOC_CTX *ctx, xlat_exp_he * they should all be talloc'd strings. */ MEM(node = xlat_exp_alloc(ctx, p->type, - talloc_get_type_abort(p->fmt, char), talloc_array_length(p->fmt) - 1)); + talloc_get_type_abort_const(p->fmt, char), talloc_array_length(p->fmt) - 1)); node->quote = p->quote; node->flags = p->flags; @@ -361,7 +361,7 @@ void xlat_exp_verify(xlat_exp_t const *node) case XLAT_FUNC: xlat_exp_head_verify(node->call.args); - (void)talloc_get_type_abort(node->fmt, char); + (void)talloc_get_type_abort_const(node->fmt, char); return; default: @@ -373,7 +373,7 @@ void xlat_exp_verify(xlat_exp_t const *node) */ void xlat_exp_head_verify(xlat_exp_head_t const *head) { - (void)talloc_get_type_abort(head, xlat_exp_head_t); + (void)talloc_get_type_abort_const(head, xlat_exp_head_t); xlat_exp_foreach(head, node) xlat_exp_verify(node); }