From 198f841c7e5632ef224839ece6caee4d700b0d01 Mon Sep 17 00:00:00 2001 From: darkvater Date: Thu, 23 Sep 2004 21:16:23 +0000 Subject: [PATCH] (svn r313) -Feature/Fix: directories in *nix are now sorted alphabetically in ascending order (Tron). --- unix.c | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/unix.c b/unix.c index 6735446cd4..2ea2fcf8a7 100644 --- a/unix.c +++ b/unix.c @@ -100,6 +100,14 @@ FiosItem *FiosGetSavegameList(int *num, int mode) closedir(dir); } + { + /* XXX ugly global variables ... */ + byte order = _savegame_sort_order; + _savegame_sort_order = 2; // sort ascending by name + qsort(_fios_items, _fios_count, sizeof(FiosItem), compare_FiosItems); + _savegame_sort_order = order; + } + // this is where to start sorting sort_start = _fios_count;