diff options
author | 2020-05-27 08:09:32 +0200 | |
---|---|---|
committer | 2020-05-27 08:09:48 +0200 | |
commit | 4d25718380e5ce02b5f94d837fb7b92ee6828269 (patch) | |
tree | 4d179677cd55805f585acd1ab596e13c7d1175fe | |
parent | 683c6d783d239343f47feef3211cca8f8783c349 (diff) |
cache: protect against savage memsets [O. Galibert]
-rw-r--r-- | src/emu/emumem.h | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/emu/emumem.h b/src/emu/emumem.h index 7767a03846f..03b8b0a74a9 100644 --- a/src/emu/emumem.h +++ b/src/emu/emumem.h @@ -2018,6 +2018,14 @@ set(address_space *space, std::pair<void *, void *> rw) }); m_root_read = (handler_entry_read <Width, AddrShift, Endian> *)(rw.first); m_root_write = (handler_entry_write<Width, AddrShift, Endian> *)(rw.second); + + // Protect against a wandering memset + m_addrstart_r = 1; + m_addrend_r = 0; + m_cache_r = nullptr; + m_addrstart_w = 1; + m_addrend_w = 0; + m_cache_w = nullptr; } template<int Width, int AddrShift, endianness_t Endian> |