-
Notifications
You must be signed in to change notification settings - Fork 357
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix endless loop when decoding OGGs, #390
In idSampleDecoderLocal::DecodeOGG() `totalSamples` was 1 and `reqSamples` was 0, which caused an endless loop.. this was caused by idSoundWorldLocal::ReadFromSaveGame() setting `chan->openalStreamingOffset` to an odd number, I think due to `currentSoundTime` being an odd number. To fix that, I round up `chan->openalStreamingOffset` to a (very) even number, and to be double-sure I also added a check in DecodeOgg() to make sure it exits the loop if `reqSamples` is 0.
- Loading branch information
1 parent
8eb91c7
commit aedf0b4
Showing
2 changed files
with
15 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters