vkback selfread: a test that freed memory a parallel test could take #45
No reviewers
Labels
No labels
accessibility
bug
documentation
duplicate
enhancement
good first issue
help wanted
invalid
question
wontfix
No milestone
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
github/vktory6--VKtory!45
Loading…
Reference in a new issue
No description provided.
Delete branch "github-bot/gh-45"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
@Mhyster on GitHub · 2026-12-01 03:59 UTC · original
Mhyster:fix-selfread-race→main· +6 −3 · 1 files · 1 commits · merged 2026-12-01 08:12 UTCWhat
selfread::tests::a_peek_that_ends_in_unmapped_memory_leaves_the_pipe_emptyunmapped the second half of its mapping to make it unreadable. The test harness runs tests in parallel, and another test'smmapcan land in the freed range, so the peek then succeeds and the test fails: 3 of 20 runs on main. The test now makes that halfPROT_NONE(still unreadable, still reserved) and unmaps the whole mapping at the end.Verification (rule 27)
cargo test -p vkback --lib30 times: 0 failures (main: 3 of 20). Test-only change, so no validation run (rule 30).🤖 Generated with Claude Code
@vktory6 on GitHub · 2026-12-01 08:12 UTC · original
Merged, thanks!
PROT_NONEkeeps the range reserved, so another test can no longer take it. Tests pass on the reference system.