mirror of
https://github.com/holub/mame
synced 2025-06-27 22:54:42 +03:00
(MESS) added check for incorrect MSX_LAYOUT_SLOT configurations (nw)
This commit is contained in:
parent
8509ab0af4
commit
823fd8ceeb
@ -859,6 +859,20 @@ void msx_state::msx_memory_init()
|
||||
size = layout->size;
|
||||
option = layout->option;
|
||||
|
||||
if (layout->type != SLOT_CARTRIDGE1 && layout->type != SLOT_CARTRIDGE2)
|
||||
{
|
||||
int size_tmp = 0;
|
||||
if (size < 0x4000)
|
||||
size_tmp = 0x4000;
|
||||
else if (size > 0x10000)
|
||||
size_tmp = 0x10000;
|
||||
else
|
||||
size_tmp = size;
|
||||
int extent_tmp = size_tmp / 0x4000;
|
||||
if (extent_tmp != extent)
|
||||
fatalerror("incorrect MSX_LAYOUT_SLOT configuration - expected extent %d but found %d\n", extent, extent_tmp);
|
||||
}
|
||||
|
||||
if (VERBOSE)
|
||||
{
|
||||
logerror ("slot %d/%d/%d-%d: type %s, size 0x%x\n",
|
||||
|
Loading…
Reference in New Issue
Block a user