Repository navigation
test(librbf): cover allocation bitmap sector boundaries - #90
Merged
DrPitre merged 1 commit intoOct 30, 2026
Merged
Conversation
Protect the OS-9/6809 RBF restriction that a file segment must not span allocation bitmap sectors. The existing SAS allocation and segment extension code already enforce this restriction; no library changes are required. Add eight deterministic regression scenarios combining one- and two-sector clusters, boundaries at cluster 2048 and 4096, and SAS sizes of one and eight clusters. Constrain free space to four clusters before each boundary and sixteen after it, starting with an empty file segment list. Verify that contiguous extension splits the file into adjacent segments at the boundary, while an eight-cluster SAS allocation skips the short free run before it. Check every segment using cluster-based bitmap sector indices, then close and reopen the file to validate persisted data and confirm that deletion succeeds. Remove each temporary image afterward. Validation: make -C build/unix succeeded, including all eight unit test suites. The librbf suite passes all 17 tests.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Protect the OS-9/6809 RBF restriction that a file segment must not span allocation bitmap sectors. The existing SAS allocation and segment extension code already enforce this restriction; no library changes are required.
Add eight deterministic regression scenarios combining one- and two-sector clusters, boundaries at cluster 2048 and 4096, and SAS sizes of one and eight clusters. Constrain free space to four clusters before each boundary and sixteen after it, starting with an empty file segment list.
Verify that contiguous extension splits the file into adjacent segments at the boundary, while an eight-cluster SAS allocation skips the short free run before it. Check every segment using cluster-based bitmap sector indices, then close and reopen the file to validate persisted data and confirm that deletion succeeds. Remove each temporary image afterward.
Validation: make -C build/unix succeeded, including all eight unit test suites. The librbf suite passes all 17 tests.