VFS: reject creation beneath existing virtual files #618
No reviewers
Labels
No labels
accessibility
bug
documentation
duplicate
enhancement
goal:world-load
good first issue
help wanted
invalid
keep-open
off-goal
question
stale
test-only
wontfix
No milestone
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
github/xcl-dev--xcl!618
Loading…
Reference in a new issue
No description provided.
Delete branch "github-bot/gh-618"
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?
@WebIdentity1 on GitHub · 2026-11-24 02:33 UTC · original
WebIdentity1:codex/vfs-file-parent-validation→main· +92 −1 · 2 files · 1 commits · draftCreating a file or directory below an original game file could create overlay directories that hide that file. Check visible ancestors before either operation changes the overlay, and return
ERROR_PATH_NOT_FOUNDfor a file parent. Existing automatic creation of missing directories and replacement of deleted originals are preserved.Part of #577, item 2 only. Item 1 is being investigated by fladit123; item 3 is outside this patch. #316 changes classification in the same file; its current diff applies cleanly to this branch, but that combined tree was not executed.
Current integration status (November24)
#1259 adds an immediate-parent directory check to
prepare_write, overlapping this PR's file-creation protection but deliberately leavingcreate_dirunchanged. It also rejects missing/removed parents, whereas this patch preserves the old automatic-parent policy and tests it. Do not combine the patches mechanically: reconcile that policy/test interaction first. No integrated result is claimed. Existing branches and evidence are preserved.What is in it
vfs.rs: parent-type check inprepare_writeandcreate_dir, with three synthetic regression tests. README documents the refusal.Tested
c741a2a85cc3527a4e15a457d791762dee67f0ef, basecb868b200517d7b11bbfcb0146bf0c787ce632b6. Windows 10 build 19045, Ryzen 7 7800X3D, RTX 3090 driver 591.74 plus AMD integrated graphics driver 32.0.21030.2001, Rust 1.98.1 MSVC, SDK DXC 1.8.2502.11, Agility 1.620.2, debug. Desktop session,XCL_ADAPTER=3090; some upstream fixtures select AMD directly.cargo build --locked --workspace: succeeded for both trees. Candidatecargo test --locked --workspace --no-fail-fast -- --test-threads=4 --show-output: 687 passed, 1 failed, 41 ignored. Onlygpu_clamp_and_omod_per_instructionfailed, also present on the baseline.gpu_uma_import_check_at_init,large_heaps_get_shared_pages_as_used,slots_copy_and_release, andcopy_descriptors_remaps_xbox_extra_cbv_srv_uav_to_pc_enumstalled. Baseline diagnostic with--test-threads=1: 684 passed, 1 failed, 41 ignored, same CLAMP failure. This patch is not claimed to fix the intermittent parallel stall.gpu_geometry_wave32_prefix_count_over_a_maskandgpu_wave32_program_in_wave64_hardware(no native wave64 on NVIDIA);test_title_draws_with_a_root_signature_under_the_debug_layeranduploads_start_from_each_subresources_state(debug layer unavailable). UnsetXCL_SAMPLE_*cases return early.cargo test --locked -p xcl --lib vfs::tests:: -- --test-threads=4 --show-output: old runtime plus the new tests 10/3/0; candidate 12/1/0. Both new rejection tests fail before the fix and pass after; native Win32 rejects with error 3. The third test preserves missing/deleted-parent behavior. The remaining focused failure is the existingtruncate_existing_validation_errors(127 vs 5), present in both trees; it passes in the completed full-suite runs. Its firstunder_wine()call precedesGetLastError()and can overwrite the error.Regression run
Independent contributor Anon64 supplied these exact-head/main runs, copied verbatim. These are their measurements, not ours. RTX3060 12GB driver581.80, i9-14900KF, Windows11 26200.9974, Rust1.90.0, release; same title/duration, clean source,
scripts/smoke.ps1. They did not test whether that title writes below a game file; our synthetic tests cover the error path.Draft retained: conflicts with current main and required CI remains outstanding. The code/head is unchanged; these runs do not qualify any future refresh.
Not tested
By us: retail behavior, release builds, Wine, concurrent namespace changes, or a combined tree with #316. The independent startup smoke above is not direct validation of the changed error path. No claim of the retail title gameplay progress.
AI use
Codex (GPT-6) inspected the issue and overlap, implemented the patch and synthetic tests, ran native Windows validation, and prepared this description.
@Anon64 on GitHub · 2026-11-24 07:01 UTC · original
Regression runs for this PR's head
c741a2aand for its basemaincb868b2, on a retail title (same title, 60 s each), made withscripts/smoke.ps1(release, clean tree at each commit) and pasted unedited, for Regression run.main:
this PR:
Tested
Not tested
Report written with Claude Code (Claude Opus 5.5) from runs on this machine.
@DavidM1911 on GitHub · 2026-11-25 12:55 UTC · original
Verification on RTX 3060 Ti (Windows 11): merge conflict with current
main— needs a rebase before it can be tested.View command line instructions
Manual merge helper
Use this merge commit message when completing the merge manually.
Checkout
From your project repository, check out a new branch and test the changes.Merge
Merge the changes and update on Forgejo.