diff options
Diffstat (limited to 'src/autoreplace_gui.cpp')
-rw-r--r-- | src/autoreplace_gui.cpp | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/src/autoreplace_gui.cpp b/src/autoreplace_gui.cpp index 49c00f4fe..3d00bfa3b 100644 --- a/src/autoreplace_gui.cpp +++ b/src/autoreplace_gui.cpp @@ -58,11 +58,9 @@ enum ReplaceVehicleWindowWidgets { RVW_WIDGET_TRAIN_WAGONREMOVE_TOGGLE, }; -static int CDECL EngineNumberSorter(const void *a, const void *b) +static int CDECL EngineNumberSorter(const EngineID *a, const EngineID *b) { - const EngineID va = *(const EngineID*)a; - const EngineID vb = *(const EngineID*)b; - int r = ListPositionOfEngine(va) - ListPositionOfEngine(vb); + int r = ListPositionOfEngine(*a) - ListPositionOfEngine(*b); return r; } |