mirror of
https://github.com/holub/mame
synced 2025-04-23 00:39:36 +03:00
added more asserts/notes for known index out-of-bounds accesses (nw)
This commit is contained in:
parent
68f8eeda6e
commit
9964b649eb
@ -292,6 +292,7 @@ WRITE8_MEMBER(maygay1b_state::m1_8279_w)
|
||||
}
|
||||
if ( chip->write_display )
|
||||
{ // Data
|
||||
assert(chip->disp_address >= 0 && chip->disp_address < ARRAY_LENGTH(chip->ram));
|
||||
if ( chip->ram[chip->disp_address] != data )
|
||||
{
|
||||
m1_draw_lamps(chip->ram[chip->disp_address],chip->disp_address, 0);
|
||||
|
@ -221,6 +221,7 @@ void atari_motion_objects_device::draw(bitmap_ind16 &bitmap, const rectangle &cl
|
||||
if (m_reverse)
|
||||
{
|
||||
first = m_activelast - 4;
|
||||
// TODO: this sets last to index m_activelist[-4]
|
||||
last = m_activelist - 4;
|
||||
step = -4;
|
||||
}
|
||||
|
@ -556,6 +556,7 @@ void namcona1_state::draw_background(screen_device &screen, bitmap_ind16 &bitmap
|
||||
gfx_element *pGfx;
|
||||
|
||||
pGfx = m_gfxdecode->gfx(0);
|
||||
assert(which >= 0 && which < ARRAY_LENGTH(m_tilemap_palette_bank));
|
||||
paldata = &m_palette->pen(pGfx->colorbase() + pGfx->granularity() * m_tilemap_palette_bank[which]);
|
||||
|
||||
/* draw one scanline at a time */
|
||||
|
Loading…
Reference in New Issue
Block a user