From 3e107c1eb06a33f1cbb8442a5a5732f98dfa4823 Mon Sep 17 00:00:00 2001 From: Colin Snover Date: Sun, 24 Sep 2017 03:40:50 -0500 Subject: SCI32: Allow invalid references to be passed to kFileIO Near the end of the game, RAMA will start trying to store some invalid references. This does not affect the save game negatively in any way, but it was causing the kernel to assert a signature failure. --- engines/sci/engine/kernel_tables.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'engines/sci/engine/kernel_tables.h') diff --git a/engines/sci/engine/kernel_tables.h b/engines/sci/engine/kernel_tables.h index 6a45241817..4002062db9 100644 --- a/engines/sci/engine/kernel_tables.h +++ b/engines/sci/engine/kernel_tables.h @@ -326,7 +326,7 @@ static const SciKernelMapSubEntry kFileIO_subops[] = { { SIG_SINCE_SCI21MID, 14, MAP_CALL(FileIOWriteByte), "ii", NULL }, { SIG_SINCE_SCI21MID, 15, MAP_CALL(FileIOReadWord), "i", NULL }, { SIG_SCI21MID_LATE, 16, MAP_CALL(FileIOWriteWord), "ii", NULL }, - { SIG_SCI3, 16, MAP_CALL(FileIOWriteWord), "i.", NULL }, + { SIG_SCI3, 16, MAP_CALL(FileIOWriteWord), "i[.!]", NULL }, { SIG_SINCE_SCI21MID, 17, "FileIOCheckFreeSpace", kCheckFreeSpace, "i(r)", NULL }, { SIG_SINCE_SCI21MID, 18, MAP_CALL(FileIOGetCWD), "r", NULL }, { SIG_SINCE_SCI21MID, 19, MAP_CALL(FileIOIsValidDirectory), "[ro]", NULL }, @@ -698,7 +698,7 @@ static SciKernelMapEntry s_kernelMap[] = { { "FGets", kFileIOReadString, SIG_EVERYWHERE, "rii", NULL, NULL }, { "FOpen", kFileIOOpen, SIG_EVERYWHERE, "ri", NULL, NULL }, { "FPuts", kFileIOWriteString, SIG_EVERYWHERE, "ir", NULL, NULL }, - { MAP_CALL(FileIO), SIG_EVERYWHERE, "i(.*)", kFileIO_subops, NULL }, + { MAP_CALL(FileIO), SIG_EVERYWHERE, "i([.!]*)", kFileIO_subops, NULL }, { MAP_CALL(FindKey), SIG_EVERYWHERE, "l.", NULL, kFindKey_workarounds }, { MAP_CALL(FirstNode), SIG_EVERYWHERE, "[l0]", NULL, NULL }, { MAP_CALL(FlushResources), SIG_EVERYWHERE, "i", NULL, NULL }, -- cgit v1.2.3