prevent division by zero, part 1
This commit is contained in:
parent
6960112f69
commit
b24c572632
4 changed files with 6 additions and 4 deletions
|
|
@ -4017,7 +4017,7 @@ SafeWriter* DivEngine::saveVGM(bool* sysToExport, bool loop) {
|
|||
}
|
||||
}
|
||||
if (nextToTouch>=0) {
|
||||
double waitTime=totalWait+(loopTimer[nextToTouch]*(44100.0/loopFreq[nextToTouch]));
|
||||
double waitTime=totalWait+(loopTimer[nextToTouch]*(44100.0/MIN(1,loopFreq[nextToTouch])));
|
||||
if (waitTime>0) {
|
||||
w->writeC(0x61);
|
||||
w->writeS(waitTime);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue