diff options
author | Christopher Page | 2008-08-10 21:58:18 +0000 |
---|---|---|
committer | Christopher Page | 2008-08-10 21:58:18 +0000 |
commit | fcc00f20b93d719c9f7bce848ed7c3600be982b9 (patch) | |
tree | 48b9fd1c842cb376985a91592ef7b062fed0cfa7 /common/system.cpp | |
parent | ce3d1e1a7d9ec9860d3fc42d8127a1634051d950 (diff) | |
parent | 9d0b0523cf119fdc400bf477c2f9d6f4f37ddce6 (diff) | |
download | scummvm-rg350-fcc00f20b93d719c9f7bce848ed7c3600be982b9.tar.gz scummvm-rg350-fcc00f20b93d719c9f7bce848ed7c3600be982b9.tar.bz2 scummvm-rg350-fcc00f20b93d719c9f7bce848ed7c3600be982b9.zip |
Merged revisions 33719,33721-33723,33725-33727,33729-33730,33733,33736,33742,33754,33756,33758,33761,33763,33766 via svnmerge from
https://scummvm.svn.sourceforge.net/svnroot/scummvm/scummvm/trunk
svn-id: r33769
Diffstat (limited to 'common/system.cpp')
-rw-r--r-- | common/system.cpp | 18 |
1 files changed, 4 insertions, 14 deletions
diff --git a/common/system.cpp b/common/system.cpp index 3e07e4ac4c..d0548cdd2d 100644 --- a/common/system.cpp +++ b/common/system.cpp @@ -163,25 +163,15 @@ static Common::String getDefaultConfigFileName() { } Common::SeekableReadStream *OSystem::openConfigFileForReading() { - Common::File *confFile = new Common::File(); - assert(confFile); - if (!confFile->open(getDefaultConfigFileName())) { - delete confFile; - confFile = 0; - } - return confFile; + FilesystemNode file(getDefaultConfigFileName()); + return file.openForReading(); } Common::WriteStream *OSystem::openConfigFileForWriting() { #ifdef __DC__ return 0; #else - Common::DumpFile *confFile = new Common::DumpFile(); - assert(confFile); - if (!confFile->open(getDefaultConfigFileName())) { - delete confFile; - confFile = 0; - } - return confFile; + FilesystemNode file(getDefaultConfigFileName()); + return file.openForWriting(); #endif } |