diff options
author | Colin Snover | 2017-11-14 22:30:35 -0600 |
---|---|---|
committer | Eugene Sandulenko | 2017-11-18 22:35:12 +0100 |
commit | e2367f3ed2060b273559200b3e40f75a98bb6a6f (patch) | |
tree | cfea744f09c075bedb9b3f4a3e9489bf5b14d829 /engines/fullpipe/utils.cpp | |
parent | 39ea2f66ac635613c3a817c16f80b11ac207d320 (diff) | |
download | scummvm-rg350-e2367f3ed2060b273559200b3e40f75a98bb6a6f.tar.gz scummvm-rg350-e2367f3ed2060b273559200b3e40f75a98bb6a6f.tar.bz2 scummvm-rg350-e2367f3ed2060b273559200b3e40f75a98bb6a6f.zip |
FULLPIPE: Remove unnecessary and unsafe C-style casts
Diffstat (limited to 'engines/fullpipe/utils.cpp')
-rw-r--r-- | engines/fullpipe/utils.cpp | 20 |
1 files changed, 2 insertions, 18 deletions
diff --git a/engines/fullpipe/utils.cpp b/engines/fullpipe/utils.cpp index 72a3377f74..f3f07b0514 100644 --- a/engines/fullpipe/utils.cpp +++ b/engines/fullpipe/utils.cpp @@ -45,22 +45,6 @@ bool CObject::loadFile(const Common::String &fname) { return load(archive); } -bool ObList::load(MfcArchive &file) { - debugC(5, kDebugLoading, "ObList::load()"); - int count = file.readCount(); - - debugC(9, kDebugLoading, "ObList::count: %d:", count); - - for (int i = 0; i < count; i++) { - debugC(9, kDebugLoading, "ObList::[%d]", i); - CObject *t = file.readClass(); - - push_back(t); - } - - return true; -} - bool ObArray::load(MfcArchive &file) { debugC(5, kDebugLoading, "ObArray::load()"); int count = file.readCount(); @@ -68,7 +52,7 @@ bool ObArray::load(MfcArchive &file) { resize(count); for (int i = 0; i < count; i++) { - CObject *t = file.readClass(); + CObject *t = file.readClass<CObject>(); push_back(*t); } @@ -379,7 +363,7 @@ void MfcArchive::init() { _objectIdMap.push_back(kNullObject); } -CObject *MfcArchive::readClass() { +CObject *MfcArchive::readBaseClass() { bool isCopyReturned; CObject *res = parseClass(&isCopyReturned); |