From: Alan T. DeKok Date: Thu, 26 May 2022 14:19:47 +0000 (-0400) Subject: minor fixes for printing X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=c4bab981786a0d30142513c7b42be9ce87fe68b8;p=thirdparty%2Ffreeradius-server.git minor fixes for printing once we've moved the arguments into our own array, we have to print spaces ourselves. --- diff --git a/src/lib/unlang/xlat_expr.c b/src/lib/unlang/xlat_expr.c index ffc1f0b2793..2c985cb7ddb 100644 --- a/src/lib/unlang/xlat_expr.c +++ b/src/lib/unlang/xlat_expr.c @@ -395,8 +395,9 @@ static fr_slen_t xlat_expr_print_logical(fr_sbuff_t *out, xlat_exp_t const *node xlat_print(out, inst->argv[i], e_rules); if (i == (inst->argc - 1)) break; - FR_SBUFF_IN_STRCPY_RETURN(out, fr_tokens[node->call.func->token]); FR_SBUFF_IN_CHAR_RETURN(out, ' '); + FR_SBUFF_IN_STRCPY_RETURN(out, fr_tokens[node->call.func->token]); + if ((i + 1) < inst->argc) FR_SBUFF_IN_CHAR_RETURN(out, ' '); } }