aboutsummaryrefslogtreecommitdiff
path: root/engines/toon/detection.cpp
diff options
context:
space:
mode:
authorStrangerke2014-02-28 23:39:35 +0100
committerStrangerke2014-02-28 23:39:35 +0100
commitc456b0e0e3f22333c0267692fe939b648e7a96c1 (patch)
tree31a981352f37916d8f76dae6a14fbd663363faa0 /engines/toon/detection.cpp
parent460645393e7333427f67d0a567edbd60d9b69b7b (diff)
downloadscummvm-rg350-c456b0e0e3f22333c0267692fe939b648e7a96c1.tar.gz
scummvm-rg350-c456b0e0e3f22333c0267692fe939b648e7a96c1.tar.bz2
scummvm-rg350-c456b0e0e3f22333c0267692fe939b648e7a96c1.zip
TOON: Reduce the scope of some more variables.
Diffstat (limited to 'engines/toon/detection.cpp')
-rw-r--r--engines/toon/detection.cpp3
1 files changed, 1 insertions, 2 deletions
diff --git a/engines/toon/detection.cpp b/engines/toon/detection.cpp
index 7c6eae6c63..4f82514213 100644
--- a/engines/toon/detection.cpp
+++ b/engines/toon/detection.cpp
@@ -179,10 +179,9 @@ SaveStateList ToonMetaEngine::listSaves(const char *target) const {
sort(filenames.begin(), filenames.end()); // Sort (hopefully ensuring we are sorted numerically..)
SaveStateList saveList;
- int slotNum = 0;
for (Common::StringArray::const_iterator filename = filenames.begin(); filename != filenames.end(); ++filename) {
// Obtain the last 3 digits of the filename, since they correspond to the save slot
- slotNum = atoi(filename->c_str() + filename->size() - 3);
+ int slotNum = atoi(filename->c_str() + filename->size() - 3);
if (slotNum >= 0 && slotNum <= 99) {
Common::InSaveFile *file = saveFileMan->openForLoading(*filename);