From 692a769af330fe6bf11448cb9bb514988220e61b Mon Sep 17 00:00:00 2001 From: Kevin Day Date: Sun, 17 Jul 2022 09:35:06 -0500 Subject: [PATCH] Bugfix: IKI variable substitution results in incorrect parameter structure for reserved parameters. The commit 9ebfcc071f11f82b435cfa0f73e4961912571c38 didn't address this case. There is an existing "separate = F_true;" that suggest that I was planning on working on this. I probably overlooked and forgot about this block. Do not increment the parameters array and instead prepend a single space only when needed. --- level_3/fake/c/private-make-operate.c | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/level_3/fake/c/private-make-operate.c b/level_3/fake/c/private-make-operate.c index c74a02e..08abb01 100644 --- a/level_3/fake/c/private-make-operate.c +++ b/level_3/fake/c/private-make-operate.c @@ -381,20 +381,20 @@ extern "C" { if (!reserved_value[k]->array[l].used) continue; - *status = f_string_dynamic_append_nulless(reserved_value[k]->array[l], &data_make->cache_arguments.array[data_make->cache_arguments.used]); + if (separate) { + *status = f_string_dynamic_append(f_string_space_s, &data_make->cache_arguments.array[data_make->cache_arguments.used]); - if (F_status_is_error(*status)) { - fll_error_print(data_make->error, F_status_set_fine(*status), "f_string_dynamic_append_nulless", F_true); + if (F_status_is_error(*status)) { + fll_error_print(data_make->error, F_status_set_fine(*status), "f_string_dynamic_append", F_true); - break; + break; + } } - ++data_make->cache_arguments.used; - - *status = f_string_dynamics_increase(fake_default_allocation_small_d, &data_make->cache_arguments); + *status = f_string_dynamic_append_nulless(reserved_value[k]->array[l], &data_make->cache_arguments.array[data_make->cache_arguments.used]); if (F_status_is_error(*status)) { - fll_error_print(data_make->error, F_status_set_fine(*status), "f_string_dynamics_increase", F_true); + fll_error_print(data_make->error, F_status_set_fine(*status), "f_string_dynamic_append_nulless", F_true); break; } -- 1.8.3.1