From 8a2b84d598f9e22aaa1ed588553dfe0a9c360e67 Mon Sep 17 00:00:00 2001 From: AJR Date: Thu, 18 Jul 2019 21:01:32 -0400 Subject: poly88: Be safe when loading snapshots (nw) --- src/mame/machine/poly88.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/mame/machine/poly88.cpp b/src/mame/machine/poly88.cpp index f9799d2c6a8..d922cdd5a1e 100644 --- a/src/mame/machine/poly88.cpp +++ b/src/mame/machine/poly88.cpp @@ -239,7 +239,8 @@ SNAPSHOT_LOAD_MEMBER(poly88_state::snapshot_cb) switch(recordType) { case 0 : /* 00 Absolute */ - memcpy(space.get_read_ptr(address ), data + pos ,recordLen); + for (uint16_t j = 0; j < recordLen; j++) + space.write_byte(address + j, data[pos + j]); break; case 1 : /* 01 Comment */ -- cgit v1.2.3