Audio: VICTORY_XMA_DUMP and VICTORY_AUDIO_CAPTURE write nothing inside a source tree #294
No reviewers
Labels
No labels
accessibility
already-solved
bug
documentation
duplicate
enhancement
good first issue
help wanted
invalid
merged
needs-decision
needs-game-run
needs-rebase
not-merged
nvidia
obsolete
question
security
wontfix
No milestone
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
github/avatarmanz--VIctory-7900XTX!294
Loading…
Reference in a new issue
No description provided.
Delete branch "github-bot/gh-294"
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?
@sharan104 on GitHub · 2026-11-26 14:38 UTC · original
sharan104:fix/hle-dumps-outside-repo→main· +32 −2 · 4 files · 1 commits · openThe same asset-policy gap as #283, in
victory-hle. Two diagnostics switches write the title's sound wherever they point, with no check:VICTORY_XMA_DUMP(audio.rs,dump_input): the context words and input buffers (.xma) of the first 32 voices, which are the title's own audio streams.VICTORY_AUDIO_CAPTURE(audio/capture.rs): a WAV recording of what the title plays.With
scripts/play.ps1's working directory (the repository root), a relative name landed in the checkout.Fix: both go through
victory_core::ensure_outside_repofirst, via a smalloutside_repo(name, path)helper inaudio.rs. A refused path gets onewarn!and nothing is written. The XMA dump folder is checked once and kept in aOnceLock. The capture is checked before the recorder process is started.victory-hlenow depends onvictory-coredirectly. There's no cycle:victory-corehas no workspace dependencies, and it was already built throughvictory-gpu.Cargo.lockgains the one edge.Test:
sound_is_not_written_into_the_source_tree(diagnostics): a folder inside the crate is refused, and a temp folder is accepted.Results:
cargo test -p victory-hle --locked --features diagnostics: the audio tests pass.cargo clippy -p victory-hle --all-targets --locked --no-deps -- -D warningsis clean, with and without--all-features.This touches different lines of
audio.rsfrom #248: the helper and the first lines ofdump_input, and a test at the top of the module. The two merge independently.🤖 Generated with Claude Code
View command line instructions
Checkout
From your project repository, check out a new branch and test the changes.Merge
Merge the changes and update on Forgejo.