summaryrefslogtreecommitdiff
path: root/StormLib/src/SFileAttributes.cpp
diff options
context:
space:
mode:
authorDavid Racine <bass_dr@hotmail.com>2026-07-13 08:12:43 -0400
committerGitHub <noreply@github.com>2026-07-13 12:12:43 +0000
commitfdb7e194cca951888326d67a5537336afa8acf8c (patch)
treeb44fe4b9b8b913f19bb7f8971e4419a7cd8a1dcd /StormLib/src/SFileAttributes.cpp
parentff7eb482d4c8b2cab93b2123e231bcb64f285160 (diff)
fix(audio): bounds-check fontId to stop OOB crash with large SAF packs (#6916)
AudioLoad_IsFontLoadComplete had a stub `return true` that bypassed all load-status checks, masking an out-of-bounds write: for large SAF packs (many custom sequences) SetFontLoadStatus indexed fontLoadStatus[] with fontId values larger than the fontMapSize-sized array, causing heap corruption and semi-random crashes. Remove the stub. Add a (size_t)fontId >= fontMapSize guard in both the check and the setter: out-of-range IDs (custom SAF sequences that carry no associated soundfont) are treated as "loaded" in the check and silently skipped in the write, matching prior observable behavior while eliminating the OOB access. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Diffstat (limited to 'StormLib/src/SFileAttributes.cpp')
0 files changed, 0 insertions, 0 deletions