From 39ff9938d8771155f9e10696bde997f9c1f240eb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Oliver=20St=C3=B6neberg?= Date: Sat, 11 Aug 2012 09:57:46 +0000 Subject: [PATCH] remived some redundant assignments (also fixes uninitialized array in karnov) (no whatsnew) --- src/emu/debug/dvmemory.c | 1 - src/emu/machine/8237dma.c | 1 - src/emu/machine/amigafdc.c | 1 - src/emu/video/mc6845.c | 7 +------ src/mame/drivers/halleys.c | 2 +- src/mame/drivers/karnov.c | 2 +- src/mame/machine/acitya.c | 4 ---- src/mame/machine/theglobp.c | 4 ---- 8 files changed, 3 insertions(+), 19 deletions(-) diff --git a/src/emu/debug/dvmemory.c b/src/emu/debug/dvmemory.c index cfaafbfdad1..5acec26e2cf 100644 --- a/src/emu/debug/dvmemory.c +++ b/src/emu/debug/dvmemory.c @@ -750,7 +750,6 @@ void debug_view_memory::set_bytes_per_chunk(UINT8 chunkbytes) pos.m_shift += 8 * ((pos.m_address % m_bytes_per_chunk) ^ ((source.m_endianness == ENDIANNESS_LITTLE) ? 0 : (m_bytes_per_chunk - 1))); pos.m_address -= pos.m_address % m_bytes_per_chunk; - m_recompute = m_update_pending = true; end_update_and_set_cursor_pos(pos); } diff --git a/src/emu/machine/8237dma.c b/src/emu/machine/8237dma.c index 057f626578b..370746c8fba 100644 --- a/src/emu/machine/8237dma.c +++ b/src/emu/machine/8237dma.c @@ -135,7 +135,6 @@ void i8237_device::device_reset() m_command = 0; m_drq = 0; m_mask = 0x00; - m_status = 0x0F; m_hrq = 0; m_hlda = 0; m_chan[0].m_mode = 0; diff --git a/src/emu/machine/amigafdc.c b/src/emu/machine/amigafdc.c index 59e11ea1700..5ebd1e2f2da 100644 --- a/src/emu/machine/amigafdc.c +++ b/src/emu/machine/amigafdc.c @@ -86,7 +86,6 @@ void amiga_fdc::device_reset() adkcon = 0; dmacon = 0; dskpt = 0; - dsklen = 0x4000; pre_dsklen = 0x4000; dma_value = 0; dma_state = DMA_IDLE; diff --git a/src/emu/video/mc6845.c b/src/emu/video/mc6845.c index e85b08c1b10..ee517aed421 100644 --- a/src/emu/video/mc6845.c +++ b/src/emu/video/mc6845.c @@ -814,17 +814,12 @@ void mc6845_device::device_start() m_horiz_disp = m_vert_disp = 0; m_vert_sync_pos = 0; m_vert_total_adj = 0; - m_cursor_start_ras = m_cursor_end_ras = 0; + m_cursor_start_ras = m_cursor_end_ras = m_cursor_addr = 0; m_cursor_blink_count = 0; m_cursor_state = 0; m_update_ready_bit = 0; - m_cursor_state = 0; - m_raster_counter = 0; - m_cursor_start_ras = 0; - m_cursor_end_ras = m_cursor_addr = 0; m_line_address = 0; m_current_disp_addr = 0; - m_line_address = 0; save_item(NAME(m_hpixels_per_column)); save_item(NAME(m_register_address_latch)); diff --git a/src/mame/drivers/halleys.c b/src/mame/drivers/halleys.c index caf6fb783b8..1b24775543a 100644 --- a/src/mame/drivers/halleys.c +++ b/src/mame/drivers/halleys.c @@ -422,7 +422,7 @@ if (0) { // clip objects against the visible area yclip = y; xclip = x; hclip = h; wclip = w; - src_yskip = src_xskip = dst_skip = 0; + src_yskip = src_xskip = 0; if (yclip < VIS_MINY) { src_yskip = VIS_MINY - yclip; yclip = VIS_MINY; hclip -= src_yskip; } if (yclip + hclip > VIS_MAXY+1) { hclip = VIS_MAXY+1 - yclip; } if (xclip < VIS_MINX) { src_xskip = VIS_MINX - xclip; xclip = VIS_MINX; wclip -= src_xskip; } diff --git a/src/mame/drivers/karnov.c b/src/mame/drivers/karnov.c index 98e0c070b5f..830602de41f 100644 --- a/src/mame/drivers/karnov.c +++ b/src/mame/drivers/karnov.c @@ -799,7 +799,7 @@ static MACHINE_RESET( karnov ) state->m_flipscreen = 0; state->m_scroll[0] = 0; - state->m_scroll[0] = 0; + state->m_scroll[1] = 0; } diff --git a/src/mame/machine/acitya.c b/src/mame/machine/acitya.c index 5866e5ab03e..bd676faa36e 100644 --- a/src/mame/machine/acitya.c +++ b/src/mame/machine/acitya.c @@ -33,7 +33,6 @@ static void acitya_decrypt_rom_8(running_machine &machine) /* Note: D2 is inverted and connected to D1, D5 is inverted and connected to D0. The other six data bits are converted by a PAL10H8 driven by the counter. */ - newbyte = 0; /* Direct inversion */ newbyte = (inverted_oldbyte & 0x80) >> 2; @@ -68,7 +67,6 @@ static void acitya_decrypt_rom_9(running_machine &machine) /* Note: D2 is inverted and connected to D1, D5 is inverted and connected to D0. The other six data bits are converted by a PAL10H8 driven by the counter. */ - newbyte = 0; /* Direct inversion */ newbyte = (inverted_oldbyte & 0x80) >> 0; @@ -101,7 +99,6 @@ static void acitya_decrypt_rom_A(running_machine &machine) /* Note: D2 is inverted and connected to D1, D5 is inverted and connected to D0. The other six data bits are converted by a PAL10H8 driven by the counter. */ - newbyte = 0; newbyte = (inverted_oldbyte & 0x80) >> 2; newbyte |= (inverted_oldbyte & 0x40) >> 2; @@ -134,7 +131,6 @@ static void acitya_decrypt_rom_B(running_machine &machine) /* Note: D2 is inverted and connected to D1, D5 is inverted and connected to D0. The other six data bits are converted by a PAL10H8 driven by the counter. */ - newbyte = 0; /* Direct inversion */ newbyte = (inverted_oldbyte & 0x80) >> 0; diff --git a/src/mame/machine/theglobp.c b/src/mame/machine/theglobp.c index 501f6eebf35..f9c32fc9958 100644 --- a/src/mame/machine/theglobp.c +++ b/src/mame/machine/theglobp.c @@ -82,7 +82,6 @@ static void theglobp_decrypt_rom_8(running_machine &machine) /* Note: D2 is inverted and connected to D1, D5 is inverted and connected to D0. The other six data bits are converted by a PAL10H8 driven by the counter. */ - newbyte = 0; /* Direct inversion */ newbyte = (inverted_oldbyte & 0x04) >> 1; @@ -118,7 +117,6 @@ static void theglobp_decrypt_rom_9(running_machine &machine) /* Note: D2 is inverted and connected to D1, D5 is inverted and connected to D0. The other six data bits are converted by a PAL10H8 driven by the counter. */ - newbyte = 0; /* Direct inversion */ newbyte = (inverted_oldbyte & 0x04) >> 1; @@ -153,7 +151,6 @@ static void theglobp_decrypt_rom_A(running_machine &machine) /* Note: D2 is inverted and connected to D1, D5 is inverted and connected to D0. The other six data bits are converted by a PAL10H8 driven by the counter. */ - newbyte = 0; /* Direct inversion */ newbyte = (inverted_oldbyte & 0x04) >> 1; @@ -188,7 +185,6 @@ static void theglobp_decrypt_rom_B(running_machine &machine) /* Note: D2 is inverted and connected to D1, D5 is inverted and connected to D0. The other six data bits are converted by a PAL10H8 driven by the counter. */ - newbyte = 0; /* Direct inversion */ newbyte = (inverted_oldbyte & 0x04) >> 1;