forked from rosebudai/OpenRCT2-Web
Restore checking of last entry's size
This commit is contained in:
1 parent
5c2e55723b
commit
f458dec3e9
1 file changed
+2
@@ -140,6 +140,8 @@ static void object_list_sort()
|
||||
sortLUT[i] = i;
|
||||
} while (++i < numObjects && (entry = object_get_next(entry)));
|
||||
qsort(sortLUT, numObjects, sizeof(size_t), object_comparator);
|
||||
// Get size of last entry so buffer is allocated properly.
|
||||
entry = object_get_next(entry);
|
||||
|
||||
// Get buffer size
|
||||
bufferSize = (uintptr_t)entry - (uintptr_t)*objectBuffer;
|
||||
|
||||
Reference in new issue
Block a user