aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--engines/sci/engine/kmisc.cpp9
1 files changed, 7 insertions, 2 deletions
diff --git a/engines/sci/engine/kmisc.cpp b/engines/sci/engine/kmisc.cpp
index 723aece819..907e0ba2e4 100644
--- a/engines/sci/engine/kmisc.cpp
+++ b/engines/sci/engine/kmisc.cpp
@@ -151,8 +151,13 @@ reg_t kMemorySegment(EngineState *s, int argc, reg_t *argv) {
if (!size)
size = s->_segMan->strlen(argv[1]) + 1;
- if (size > EngineState::kMemorySegmentMax)
- size = EngineState::kMemorySegmentMax;
+ if (size > EngineState::kMemorySegmentMax) {
+ // This was set to cut the block to 256 bytes. This should be an
+ // error, as we won't restore the full block that the game scripts
+ // request, thus error out instead.
+ //size = EngineState::kMemorySegmentMax;
+ error("kMemorySegment: Requested to save more than 256 bytes (%d)", size);
+ }
s->_memorySegmentSize = size;