1
0
mirror of https://github.com/OpenRCT2/OpenRCT2 synced 2025-12-23 15:52:55 +01:00

Crash using benchspritesort with dimensions not divisible by 32 (#10743)

Fixes #10740
This commit is contained in:
ζeh Matt
2020-02-19 21:50:13 +01:00
committed by GitHub
parent ae814571df
commit 1272c0c043

View File

@@ -952,7 +952,7 @@ void viewport_paint(
if (recorded_sessions != nullptr)
{
const uint16_t columnSize = rightBorder - alignedX;
const uint16_t columnCount = (columnSize / 32);
const uint16_t columnCount = (columnSize + 31) / 32;
recorded_sessions->resize(columnCount);
}