aboutsummaryrefslogtreecommitdiff
path: root/engines/scumm/he/script_v60he.cpp
diff options
context:
space:
mode:
authorMax Horn2008-09-30 09:09:39 +0000
committerMax Horn2008-09-30 09:09:39 +0000
commit96faab42711cb582607b61a7d031217609e86d11 (patch)
tree1312023b8ac65c8bfca7552aba15e435429b49a3 /engines/scumm/he/script_v60he.cpp
parent82f7b3e6e4044fa0f6e43dc07a7ed36ee14a111d (diff)
downloadscummvm-rg350-96faab42711cb582607b61a7d031217609e86d11.tar.gz
scummvm-rg350-96faab42711cb582607b61a7d031217609e86d11.tar.bz2
scummvm-rg350-96faab42711cb582607b61a7d031217609e86d11.zip
SCUMM HE: Use FilesystemNode::openForReading() instead of 'new Common::File' (didn't cover all instances, though)
svn-id: r34694
Diffstat (limited to 'engines/scumm/he/script_v60he.cpp')
-rw-r--r--engines/scumm/he/script_v60he.cpp8
1 files changed, 2 insertions, 6 deletions
diff --git a/engines/scumm/he/script_v60he.cpp b/engines/scumm/he/script_v60he.cpp
index 7f36d53791..4af2138cad 100644
--- a/engines/scumm/he/script_v60he.cpp
+++ b/engines/scumm/he/script_v60he.cpp
@@ -1010,12 +1010,8 @@ void ScummEngine_v60he::o60_openFile() {
// TODO / FIXME: Consider using listSavefiles to avoid unneccessary openForLoading calls
_hInFileTable[slot] = _saveFileMan->openForLoading(filename);
if (_hInFileTable[slot] == 0) {
- Common::File *f = new Common::File();
- f->open(filename);
- if (!f->isOpen())
- delete f;
- else
- _hInFileTable[slot] = f;
+ Common::FilesystemNode node(filename);
+ _hInFileTable[slot] = node.openForReading();
}
break;
case 2: