aboutsummaryrefslogtreecommitdiff
path: root/libpcsxcore
diff options
context:
space:
mode:
authornotaz2010-12-14 18:59:22 +0200
committernotaz2010-12-16 18:37:56 +0200
commit7b8da7ab9586be3041c25cc6109d52567eb68c70 (patch)
tree73f2a96af7ae77b0cadb0629368264e59e2947fe /libpcsxcore
parent4cb76aa4e037a59c85d0fa256fb85fe11d3405af (diff)
downloadpcsx_rearmed-7b8da7ab9586be3041c25cc6109d52567eb68c70.tar.gz
pcsx_rearmed-7b8da7ab9586be3041c25cc6109d52567eb68c70.tar.bz2
pcsx_rearmed-7b8da7ab9586be3041c25cc6109d52567eb68c70.zip
cdriso: don't try to play audio if tracks are missing
to prevent random noise
Diffstat (limited to 'libpcsxcore')
-rw-r--r--libpcsxcore/cdriso.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/libpcsxcore/cdriso.c b/libpcsxcore/cdriso.c
index 18b0de9..45199f5 100644
--- a/libpcsxcore/cdriso.c
+++ b/libpcsxcore/cdriso.c
@@ -809,6 +809,9 @@ static unsigned char * CALLBACK ISOgetBuffer(void) {
// sector: byte 0 - minute; byte 1 - second; byte 2 - frame
// does NOT uses bcd format
static long CALLBACK ISOplay(unsigned char *time) {
+ if (numtracks <= 1)
+ return 0;
+
if (SPU_playCDDAchannel != NULL) {
if (subChanMixed) {
startCDDA(MSF2SECT(time[0], time[1], time[2]) * (CD_FRAMESIZE_RAW + SUB_FRAMESIZE));