From: notaz <notasas@gmail.com>
Date: Wed, 25 Oct 2023 20:06:59 +0000 (+0300)
Subject: cdriso: unbreak chd cdda
X-Git-Tag: r24~87
X-Git-Url: https://notaz.gp2x.de/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=f0d80aa4838a05c8e86d99bb1379ba0579794e10;p=pcsx_rearmed.git

cdriso: unbreak chd cdda

fixes notaz/pcsx_rearmed#328
---

diff --git a/libpcsxcore/cdriso.c b/libpcsxcore/cdriso.c
index db57b0c5..660d109c 100644
--- a/libpcsxcore/cdriso.c
+++ b/libpcsxcore/cdriso.c
@@ -1708,7 +1708,7 @@ long CALLBACK ISOreadCDDA(unsigned char m, unsigned char s, unsigned char f, uns
 			}
 		}
 	}
-	if (!handle) {
+	if (!handle && !chd_img) {
 		memset(buffer, 0, CD_FRAMESIZE_RAW);
 		return -1;
 	}