[BUG] Named fixture paths are truncated at newlines #8

Closed
opened 2026-10-15 06:03:37 +02:00 by erikinkinen · 1 comment
Owner

Summary

The early-service and blob parsers truncate a path at its first newline and drop later entries.

Reproduction

Run the original parser statement in Bash:

EARLY_SERVICES=$'memd:/line\nbreak/memd.elf,procd:/line\nbreak/procd.elf'
IFS=',' read -r -a EARLY_SERVICE_SPECS <<<"$EARLY_SERVICES"
printf 'count=%d\n' "${#EARLY_SERVICE_SPECS[@]}"
printf 'entry=%q\n' "${EARLY_SERVICE_SPECS[@]}"

Expected and actual behavior

Both entries and their complete paths should survive in EARLY_SERVICES and BLOBS. Instead, the output is count=1 and entry=memd:/line. The later Procd entry is lost.

Environment and identity

Bootloader f9847347, scripts/build-bootimg-fixture.sh:103, selected by Integration 9c4b15c0; Bash 5.3.9. Both Integration image packagers pass the list as a quoted environment value.

Evidence and prior checks

An isolated source-bound host check reproduces the truncation. It runs the original read statement without executable files, image construction or a guest. The missing-Procd preparation repair in Integration #129 is separate.

Tracking

Phase completion.

  • Preserve complete paths and every later entry in the actual consumer.
  • Cover embedded and terminal newlines through the real caller boundary.
  • Keep explicit executable selection and existing file-validation failures.
## Summary The early-service and blob parsers truncate a path at its first newline and drop later entries. ## Reproduction Run the original parser statement in Bash: ```bash EARLY_SERVICES=$'memd:/line\nbreak/memd.elf,procd:/line\nbreak/procd.elf' IFS=',' read -r -a EARLY_SERVICE_SPECS <<<"$EARLY_SERVICES" printf 'count=%d\n' "${#EARLY_SERVICE_SPECS[@]}" printf 'entry=%q\n' "${EARLY_SERVICE_SPECS[@]}" ``` ## Expected and actual behavior Both entries and their complete paths should survive in `EARLY_SERVICES` and `BLOBS`. Instead, the output is `count=1` and `entry=memd:/line`. The later Procd entry is lost. ## Environment and identity Bootloader `f9847347`, `scripts/build-bootimg-fixture.sh:103`, selected by Integration `9c4b15c0`; Bash 5.3.9. Both Integration image packagers pass the list as a quoted environment value. ## Evidence and prior checks An isolated source-bound host check reproduces the truncation. It runs the original read statement without executable files, image construction or a guest. The missing-Procd preparation repair in [Integration #129](https://git.erikinkinen.fi/erix/integration/issues/129) is separate. ## Tracking [Phase completion](https://git.erikinkinen.fi/erix/integration/issues/65). - [x] Preserve complete paths and every later entry in the actual consumer. - [x] Cover embedded and terminal newlines through the real caller boundary. - [x] Keep explicit executable selection and existing file-validation failures.
erikinkinen changed title from [BUG] Early-service paths are truncated at newlines to [BUG] Named fixture paths are truncated at newlines 2026-10-15 06:49:26 +02:00
Author
Owner

Fixed in 610f3f4f. Both lists now use one parser that preserves complete paths and validates every selected file before tool preparation. The real-script regression fixtures cover both argument copies, CR/LF bytes, literal shell syntax and later missing files.

Fixed in `610f3f4f`. Both lists now use one parser that preserves complete paths and validates every selected file before tool preparation. The real-script regression fixtures cover both argument copies, CR/LF bytes, literal shell syntax and later missing files.
erikinkinen added this to the Alpha 1 milestone 2026-10-30 09:33:35 +01:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
erix/bootloader#8
No description provided.