]> Kevux Git Server - fll/commitdiff
Bugfix: Only add extended next space when there is a next number.
authorKevin Day <kevin@kevux.org>
Sun, 3 Mar 2024 05:47:30 +0000 (23:47 -0600)
committerKevin Day <kevin@kevux.org>
Sun, 3 Mar 2024 05:47:30 +0000 (23:47 -0600)
level_1/fl_fss/c/fss/private-payload.c

index c46a713984bb2ed05d32210ac88506a7d6e72a0d..d29e84f58bb6a28526bcaec71dcf77fab98be74d 100644 (file)
@@ -1354,8 +1354,10 @@ extern "C" {
             private_fl_fss_basic_write(F_false, string_static, internal->quote, &internal->range, &destinations->array[destinations->used].value, state, (void * const) internal);
             if (F_status_is_error(state->status)) return F_true;
 
-            state->status = f_string_dynamic_append_assure(f_fss_extended_next_s, data->cache);
-            if (F_status_is_error(state->status)) return F_true;
+            if (internal->j + 1 < internal->l) {
+              state->status = f_string_dynamic_append_assure(f_fss_extended_next_s, &destinations->array[destinations->used].value);
+              if (F_status_is_error(state->status)) return F_true;
+            }
           }
           else if (data->flag & f_fss_payload_header_map_flag_null_string_e) {
             state->status = f_string_dynamic_append(internal->quote_null, &destinations->array[destinations->used].value);