Fixed several CD-ROM-related status bar icon bugs;

CD-ROM set to host drive no longer gets reset to empty;
The CD audio thread initializer now ignores the mute status of the drives;
CD-ROM IOCTL audio handler is now more thread-safe;
Fixed CD-ROM image audio;
Added more sanity checks to memory read/write code in 808x.c;
Initial settings are now sane again.
This commit is contained in:
OBattler
2017-06-01 01:47:54 +02:00
parent 339f81b553
commit e6adf90e29
12 changed files with 193 additions and 117 deletions

View File

@@ -435,16 +435,13 @@ void initmodules(void)
for (i = 0; i < CDROM_NUM; i++)
{
if (cdrom_drives[i].host_drive != 0)
if (cdrom_drives[i].host_drive == 200)
{
if (cdrom_drives[i].host_drive == 200)
{
image_reset(i);
}
else if ((cdrom_drives[i].host_drive >= 'A') && (cdrom_drives[i].host_drive <= 'Z'))
{
ioctl_reset(i);
}
image_reset(i);
}
else if ((cdrom_drives[i].host_drive >= 'A') && (cdrom_drives[i].host_drive <= 'Z'))
{
ioctl_reset(i);
}
}
}
@@ -547,16 +544,13 @@ void resetpchard(void)
for (i = 0; i < CDROM_NUM; i++)
{
if (cdrom_drives[i].host_drive != 0)
if (cdrom_drives[i].host_drive == 200)
{
if (cdrom_drives[i].host_drive == 200)
{
image_reset(i);
}
else if ((cdrom_drives[i].host_drive >= 'A') && (cdrom_drives[i].host_drive <= 'Z'))
{
ioctl_reset(i);
}
image_reset(i);
}
else if ((cdrom_drives[i].host_drive >= 'A') && (cdrom_drives[i].host_drive <= 'Z'))
{
ioctl_reset(i);
}
}