(MESS) added check for incorrect MSX_LAYOUT_SLOT configurations (nw)

This commit is contained in:
Oliver Stöneberg 2013-06-01 16:53:59 +00:00
parent 8509ab0af4
commit 823fd8ceeb

View File

@ -858,6 +858,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)
{