[Scummvm-cvs-logs] scummvm master -> 142de4fffbf079c46ed7ce3339c0f93a4f1af624

m-kiewitz m_kiewitz at users.sourceforge.net
Tue Feb 9 19:20:53 CET 2016


This automated email contains information about 1 new commit which have been
pushed to the 'scummvm' repo located at https://github.com/scummvm/scummvm .

Summary:
142de4fffb AGI: Fix skip auto-save slot code for auto-save


Commit: 142de4fffbf079c46ed7ce3339c0f93a4f1af624
    https://github.com/scummvm/scummvm/commit/142de4fffbf079c46ed7ce3339c0f93a4f1af624
Author: Martin Kiewitz (m_kiewitz at users.sourceforge.net)
Date: 2016-02-09T19:20:57+01:00

Commit Message:
AGI: Fix skip auto-save slot code for auto-save

Changed paths:
    engines/agi/systemui.cpp



diff --git a/engines/agi/systemui.cpp b/engines/agi/systemui.cpp
index 42a35a8..72017a1 100644
--- a/engines/agi/systemui.cpp
+++ b/engines/agi/systemui.cpp
@@ -640,6 +640,9 @@ void SystemUI::readSavedGameSlots(bool filterNonexistant, bool withAutoSaveSlot)
 void SystemUI::figureOutAutomaticSavedGameSlot(const char *automaticSaveDescription, int16 &matchedGameSlotId, int16 &freshGameSlotId) {
 	bool foundFresh = false;
 
+	matchedGameSlotId = -1;
+	freshGameSlotId = -1;
+
 	for (uint16 slotNr = 0; slotNr < _savedGameArray.size(); slotNr++) {
 		SystemUISavedGameEntry *savedGameEntry = &_savedGameArray[slotNr];
 
@@ -655,7 +658,7 @@ void SystemUI::figureOutAutomaticSavedGameSlot(const char *automaticSaveDescript
 			// no new slot found yet
 			if (!savedGameEntry->exists) {
 				// and current slot doesn't exist
-				if (slotNr) {
+				if (savedGameEntry->slotId) {
 					// and slot is not the auto-save slot -> remember this slot
 					freshGameSlotId = savedGameEntry->slotId;
 					foundFresh = true;






More information about the Scummvm-git-logs mailing list