From 057b39372f70c4fcbb2484f994f7d62d16bb93f5 Mon Sep 17 00:00:00 2001 From: Michael Pavone Date: Tue, 14 Feb 2017 04:44:37 -0800 Subject: Fix handling of SRAM overlapping with ROM --- romdb.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'romdb.c') diff --git a/romdb.c b/romdb.c index d97cef7..38ab36e 100644 --- a/romdb.c +++ b/romdb.c @@ -561,7 +561,7 @@ void add_memmap_header(rom_info *info, uint8_t *rom, uint32_t size, memmap_chunk info->map[1].read_8 = (read_8_fun)read_sram_b; info->map[1].write_16 = (write_16_fun)write_sram_area_w;//these will be called all writes to the area info->map[1].write_8 = (write_8_fun)write_sram_area_b; - info->map[1].buffer = rom + 0x200000 / sizeof(uint16_t); + info->map[1].buffer = rom + 0x200000; memmap_chunk *last = info->map + info->map_chunks - 1; memset(last, 0, sizeof(memmap_chunk)); -- cgit v1.2.3