mirror of https://github.com/mgba-emu/mgba.git
Qt: Fix integer overflow in frame -> seconds calculation
This commit is contained in:
parent
682ed7dcee
commit
9933c58eec
|
@ -75,7 +75,7 @@ GameController::GameController(QObject* parent)
|
|||
case GameControllerRTC::FIXED:
|
||||
return rtc->value;
|
||||
case GameControllerRTC::FAKE_EPOCH:
|
||||
return rtc->value + rtc->p->m_threadContext.gba->video.frameCounter * VIDEO_TOTAL_LENGTH / GBA_ARM7TDMI_FREQUENCY;
|
||||
return rtc->value + rtc->p->m_threadContext.gba->video.frameCounter * (int64_t) VIDEO_TOTAL_LENGTH / GBA_ARM7TDMI_FREQUENCY;
|
||||
}
|
||||
};
|
||||
|
||||
|
|
Loading…
Reference in New Issue