diff options
author | Colin Snover | 2016-09-30 13:09:12 -0500 |
---|---|---|
committer | Colin Snover | 2016-09-30 13:54:06 -0500 |
commit | 5baff4a1e5b1635334be2c9590e1aa765a9cdcab (patch) | |
tree | cec2d02e6f23d6b715bd4da32344d4dc72665314 /engines/sci/engine | |
parent | d580b64c6e23114310511c8a4c1b9fb1a939e806 (diff) | |
download | scummvm-rg350-5baff4a1e5b1635334be2c9590e1aa765a9cdcab.tar.gz scummvm-rg350-5baff4a1e5b1635334be2c9590e1aa765a9cdcab.tar.bz2 scummvm-rg350-5baff4a1e5b1635334be2c9590e1aa765a9cdcab.zip |
SCI32: Fix some buildbot compiler warnings
Diffstat (limited to 'engines/sci/engine')
-rw-r--r-- | engines/sci/engine/kfile.cpp | 2 | ||||
-rw-r--r-- | engines/sci/engine/kgraphics32.cpp | 3 | ||||
-rw-r--r-- | engines/sci/engine/savegame.cpp | 14 |
3 files changed, 8 insertions, 11 deletions
diff --git a/engines/sci/engine/kfile.cpp b/engines/sci/engine/kfile.cpp index 2d2f885b05..76cae6c4c1 100644 --- a/engines/sci/engine/kfile.cpp +++ b/engines/sci/engine/kfile.cpp @@ -534,7 +534,7 @@ reg_t kFileIOWriteRaw(EngineState *s, int argc, reg_t *argv) { #ifdef ENABLE_SCI32 if (getSciVersion() >= SCI_VERSION_2) { if (!success) { - return make_reg(0, -1); + return SIGNAL_REG; } return make_reg(0, bytesWritten); diff --git a/engines/sci/engine/kgraphics32.cpp b/engines/sci/engine/kgraphics32.cpp index 49215b27f4..b8dc3e45b8 100644 --- a/engines/sci/engine/kgraphics32.cpp +++ b/engines/sci/engine/kgraphics32.cpp @@ -75,10 +75,7 @@ reg_t kBaseSetter32(EngineState *s, int argc, reg_t *argv) { CelObjView celObj(viewId, loopNo, celNo); const int16 scriptWidth = g_sci->_gfxFrameout->getCurrentBuffer().scriptWidth; - const int16 scriptHeight = g_sci->_gfxFrameout->getCurrentBuffer().scriptHeight; - const Ratio scaleX(scriptWidth, celObj._scaledWidth); - const Ratio scaleY(scriptHeight, celObj._scaledHeight); int16 brLeft; diff --git a/engines/sci/engine/savegame.cpp b/engines/sci/engine/savegame.cpp index 36c35e47ea..4153b8e1af 100644 --- a/engines/sci/engine/savegame.cpp +++ b/engines/sci/engine/savegame.cpp @@ -667,32 +667,32 @@ void ArrayTable::saveLoadWithSerializer(Common::Serializer &ser) { } void SciArray::saveLoadWithSerializer(Common::Serializer &s) { - uint16 size; + uint16 savedSize; if (s.isSaving()) { - size = _size; + savedSize = _size; } s.syncAsByte(_type); s.syncAsByte(_elementSize); - s.syncAsUint16LE(size); + s.syncAsUint16LE(savedSize); if (s.isLoading()) { - resize(size); + resize(savedSize); } switch (_type) { case kArrayTypeByte: case kArrayTypeString: - s.syncBytes((byte *)_data, size); + s.syncBytes((byte *)_data, savedSize); break; case kArrayTypeInt16: - for (int i = 0; i < size; ++i) { + for (int i = 0; i < savedSize; ++i) { s.syncAsUint16LE(((int16 *)_data)[i]); } break; case kArrayTypeID: - for (int i = 0; i < size; ++i) { + for (int i = 0; i < savedSize; ++i) { syncWithSerializer(s, ((reg_t *)_data)[i]); } break; |