Previous 199869 Revisions Next

r33052 Wednesday 29th October, 2014 at 13:21:12 UTC by Oliver Stöneberg
fixed usage of uninitialized members in sns_sa1_device (nw)

happened with e.g. snes -cart sdf1gpp
[src/emu/bus/snes]sa1.c

trunk/src/emu/bus/snes/sa1.c
r241563r241564
9696
9797void sns_sa1_device::device_start()
9898{
99   m_scpu_ctrl = 0;
100   m_nmi_vector = 0;
101   m_bank_c_hi = 0;
102   m_bank_c_rom = 0;
99103}
100104
101105void sns_sa1_device::device_reset()
102106{
103   memset(m_internal_ram, 0, 0x800);
107   memset(m_internal_ram, 0, sizeof(m_internal_ram));
104108
105109   m_sa1_ctrl = 0x20;
106110   m_scpu_ctrl = 0;
r241563r241564
127131   m_iram_write_sa1 = 1;
128132   m_src_addr = 0;
129133   m_dst_addr = 0;
130   memset(m_brf_reg, 0, 0x10);
134   memset(m_brf_reg, 0, sizeof(m_brf_reg));
131135   m_math_ctlr = 0;
132136   m_math_overflow = 0;
133137   m_math_a = 0;


Previous 199869 Revisions Next


© 1997-2024 The MAME Team