diff options
| author | David Racine <bass_dr@hotmail.com> | 2026-06-12 23:36:25 -0400 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2026-06-13 03:36:25 +0000 |
| commit | eb4142835eba466852cdf8d588f548a5c6d7c9fe (patch) | |
| tree | 8eb0bbe4c67be9904e322899e84ecfc14530ce87 /StormLib/src | |
| parent | f3413bfd26f9c9f95b7bc46359bc919423e2a3ad (diff) | |
Fix custom music corruption past 256 sequences (#5989) (#6736)
The resolved replacement id (which can exceed 255) rode a single
per-player seqToPlay slot, written at enqueue but consumed
asynchronously on the audio thread; back-to-back starts and
priority-queue promotions clobbered it. sSeqFlags[0x6F] was also indexed
by raw id, reading out of bounds past the authentic range.
- func_800F9280 resolves the replacement and packs the full 16-bit id
into the 0x82/0x85 play command; the handler reads opArgs & 0xFFFF.
Audio_QueueSeqCmd no longer pre-writes the shared slot.
- SyncInitSeqPlayerInternal uses the command-carried id and bounds-checks
it against the calloc'd sequence map (+0xF headroom for reserved-range
skips).
- Route sSeqFlags reads through a bounded Audio_GetSeqFlags helper.
- Warn and skip gracefully past the 16-bit id limit.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Diffstat (limited to 'StormLib/src')
0 files changed, 0 insertions, 0 deletions
