aboutsummaryrefslogtreecommitdiff
path: root/engines/access
diff options
context:
space:
mode:
Diffstat (limited to 'engines/access')
-rw-r--r--engines/access/detection.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/engines/access/detection.cpp b/engines/access/detection.cpp
index 7494c9c047..2cd7e50f0f 100644
--- a/engines/access/detection.cpp
+++ b/engines/access/detection.cpp
@@ -146,7 +146,6 @@ SaveStateList AccessMetaEngine::listSaves(const char *target) const {
Access::AccessSavegameHeader header;
filenames = saveFileMan->listSavefiles(pattern);
- sort(filenames.begin(), filenames.end()); // Sort to get the files in numerical order
SaveStateList saveList;
for (Common::StringArray::const_iterator file = filenames.begin(); file != filenames.end(); ++file) {
@@ -167,6 +166,8 @@ SaveStateList AccessMetaEngine::listSaves(const char *target) const {
}
}
+ // Sort saves based on slot number.
+ Common::sort(saveList.begin(), saveList.end(), SaveStateDescriptorSlotComparator());
return saveList;
}