From 1f035e278151a3e29b3d2077f7242787fc541216 Mon Sep 17 00:00:00 2001 From: gameblabla Date: Wed, 25 Aug 2021 21:22:44 +0000 Subject: [PATCH] CdlSync should be NULL and return an error. (#199) This has been confirmed by both Mednafen and nocash's documentation. --- libpcsxcore/cdrom.c | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/libpcsxcore/cdrom.c b/libpcsxcore/cdrom.c index 7cba92ee..1e8f950a 100644 --- a/libpcsxcore/cdrom.c +++ b/libpcsxcore/cdrom.c @@ -48,7 +48,7 @@ cdrStruct cdr; static unsigned char *pTransfer; /* CD-ROM magic numbers */ -#define CdlSync 0 +#define CdlSync 0 /* nocash documentation : "Uh, actually, returns error code 40h = Invalid Command...?" */ #define CdlNop 1 #define CdlSetloc 2 #define CdlPlay 3 @@ -575,10 +575,6 @@ void cdrInterrupt() { cdr.Irq = 0; switch (Irq) { - case CdlSync: - // TOOD: sometimes/always return error? - break; - case CdlNop: if (cdr.DriveState != DRIVESTATE_LID_OPEN) cdr.StatP &= ~STATUS_SHELLOPEN; @@ -973,7 +969,7 @@ void cdrInterrupt() { cdr.Result[0] = cdr.StatP; start_rotating = 1; break; - + case CdlSync: default: CDR_LOG_I("Invalid command: %02x\n", Irq); error = ERROR_INVALIDCMD; -- 2.39.2