mirror of https://github.com/snes9xgit/snes9x.git
Fix code gaff in reset in BSX code
This commit is contained in:
parent
94f9f6ff25
commit
dd1202a2ad
21
bsx.cpp
21
bsx.cpp
|
@ -450,7 +450,7 @@ static void map_psram_mirror_sub (uint32 bank)
|
|||
|
||||
static void BSX_Map_PSRAM(void)
|
||||
{
|
||||
int c, i;
|
||||
int c;
|
||||
|
||||
if (!BSX.MMC[0x02])
|
||||
{
|
||||
|
@ -773,7 +773,6 @@ uint8 S9xGetBSX (uint32 address)
|
|||
void S9xSetBSX (uint8 byte, uint32 address)
|
||||
{
|
||||
uint8 bank = (address >> 16) & 0xFF;
|
||||
uint16 offset = address & 0xFFFF;
|
||||
|
||||
// MMC
|
||||
if ((bank >= 0x01 && bank <= 0x0E))
|
||||
|
@ -902,8 +901,8 @@ void S9xSetBSX (uint8 byte, uint32 address)
|
|||
|
||||
void S9xBSXSetStream1 (uint8 count)
|
||||
{
|
||||
if (BSX.sat_stream1.is_open())
|
||||
BSX.sat_stream1.close(); //If Stream1 already opened for one file: Close it.
|
||||
if (BSX.sat_stream1.is_open())
|
||||
BSX.sat_stream1.close(); //If Stream1 already opened for one file: Close it.
|
||||
|
||||
char path[PATH_MAX + 1], name[PATH_MAX + 1];
|
||||
|
||||
|
@ -934,8 +933,8 @@ void S9xBSXSetStream1 (uint8 count)
|
|||
|
||||
void S9xBSXSetStream2 (uint8 count)
|
||||
{
|
||||
if (BSX.sat_stream2.is_open())
|
||||
BSX.sat_stream2.close(); //If Stream1 already opened for one file: Close it.
|
||||
if (BSX.sat_stream2.is_open())
|
||||
BSX.sat_stream2.close(); //If Stream1 already opened for one file: Close it.
|
||||
|
||||
char path[PATH_MAX + 1], name[PATH_MAX + 1];
|
||||
|
||||
|
@ -1517,12 +1516,12 @@ void S9xResetBSX (void)
|
|||
BSX.MMC[0x0E] = 0x80;
|
||||
|
||||
// stream reset
|
||||
BSX.sat_pf_latch1_enable, BSX.sat_dt_latch1_enable = FALSE;
|
||||
BSX.sat_pf_latch2_enable, BSX.sat_dt_latch2_enable = FALSE;
|
||||
BSX.sat_pf_latch1_enable = BSX.sat_dt_latch1_enable = FALSE;
|
||||
BSX.sat_pf_latch2_enable = BSX.sat_dt_latch2_enable = FALSE;
|
||||
|
||||
BSX.sat_stream1_loaded, BSX.sat_stream2_loaded = FALSE;
|
||||
BSX.sat_stream1_first, BSX.sat_stream2_first = FALSE;
|
||||
BSX.sat_stream1_count, BSX.sat_stream2_count = 0;
|
||||
BSX.sat_stream1_loaded = BSX.sat_stream2_loaded = FALSE;
|
||||
BSX.sat_stream1_first = BSX.sat_stream2_first = FALSE;
|
||||
BSX.sat_stream1_count = BSX.sat_stream2_count = 0;
|
||||
|
||||
if (BSX.sat_stream1.is_open())
|
||||
BSX.sat_stream1.close();
|
||||
|
|
Loading…
Reference in New Issue