From 33d1c558663f0b7ed5eafec999c506a55307ff27 Mon Sep 17 00:00:00 2001 From: Thierry Crozat Date: Sun, 18 Sep 2016 05:31:29 +0100 Subject: BACKENDS: Ignore timestamps for inexistent files in DefaultSaveFileManager This fixes a bug in the synchronisation of the save files to the cloud when the timestamps file contains entries for files that do no longer exist. In such a case the synchronisation would fail. --- backends/saves/default/default-saves.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'backends') diff --git a/backends/saves/default/default-saves.cpp b/backends/saves/default/default-saves.cpp index 8a7fba46f7..72d65df6e2 100644 --- a/backends/saves/default/default-saves.cpp +++ b/backends/saves/default/default-saves.cpp @@ -330,7 +330,8 @@ Common::HashMap DefaultSaveFileManager::loadTimestamps() //parse timestamp uint32 timestamp = buffer.asUint64(); if (buffer == "" || timestamp == 0) break; - timestamps[filename] = timestamp; + if (timestamps.contains(filename)) + timestamps[filename] = timestamp; } delete file; -- cgit v1.2.3