mirror of
https://github.com/OpenTTD/OpenTTD.git
synced 2025-03-06 06:15:04 +00:00
(svn r13089) -Fix (r13072): MorphOS compilation was broken
This commit is contained in:
parent
08814d50ea
commit
56f15b3544
@ -125,7 +125,7 @@ void EngList_Sort(EngineList *el, EngList_SortTypeFunction compare)
|
||||
/* out-of-bounds access at the next line for size == 0 (even with operator[] at some systems)
|
||||
* generally, do not sort if there are less than 2 items */
|
||||
if (size < 2) return;
|
||||
qsort(&(el->at(0)), size, sizeof(EngineID), compare);
|
||||
qsort(&((*el)[0]), size, sizeof(EngineID), compare); // MorphOS doesn't know vector::at(int) ...
|
||||
}
|
||||
|
||||
/** Sort selected range of items (on indices @ <begin, begin+num_items-1>)
|
||||
|
Loading…
Reference in New Issue
Block a user