Core: fix policy resolve trailing and verbatim dotdot folding (fixes #793) #973
Loading…
Reference in a new issue
No description provided.
Delete branch "upstream-pr/973"
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?
Imported from Marvisak/VIctory. Originally posted by pushkarreddyy on 2026-11-24T14:36:22Z.
Summary
Fixes
policy::resolveon trailing..and Windows verbatim\\?\prefixes, resolving #793.Changes
crates/victory-core/src/policy.rs:..without failing whenfile_name()returnsNone.\\?\prefixes when resolving paths.Verification
victory-core.cargo clippy --workspace --all-targets --locked -- -D warnings.Imported from Marvisak/VIctory. Originally posted by Zipettte on 2026-11-24T15:13:07Z.
Tested on AMD Radeon RX 7700 XT (RDNA3, gfx1101), driver 32.0.32029.2010, Windows 11, Rust 1.98.1 MSVC at
58ee9ad:cargo test -p victory-corepasses, 12 passed / 0 failed. Workspace baseline on main (ffe310e) is green on the same machine (342 passed).Tested with AI assistance (Claude).
Imported from Marvisak/VIctory. Originally posted by pushkarreddyy on 2026-11-24T15:28:43Z.
Thank you @Zipettte for testing and verifying PR #973 on AMD Radeon RX 7700 XT!
Imported from Marvisak/VIctory. Originally posted by DaniiL35 on 2026-11-24T16:18:28Z.
Reviewed and verified on macOS Darwin:
normalizehelper completely resolves the dead-code lint warning.\\?\\verbatim path representations (Component::Normal(n) if *n == "..").policy.rs(handles_trailing_dotdot_and_curdir) pass cleanly.PR is clean, minimal, and ready to merge!
Imported from Marvisak/VIctory. Originally posted by Marvisak on 2026-11-25T00:29:04Z.
Automated triage for the maintainers. Closing because another open pull request covers the same change.
See #937. Same fix as #937 (trailing '..' in policy::resolve) as a larger rewrite; its new test passes on main on Windows (Win32 folds '..' before the open), so it does not exercise the fix, and the extra Normal("..") arms are dead code.
If this is mistaken, reply here with what was missed (or push a change and say so) and it will be looked at again. Thank you for the contribution.
Pull request closed