}
}
numtracks = 0;
+ ti[1].type = 0;
UnloadSBI();
+ memset(cdbuffer, 0, sizeof(cdbuffer));
+ CDR_getBuffer = ISOgetBuffer;
+
return 0;
}
// uses bcd format
static long CALLBACK ISOreadTrack(unsigned char *time) {
int sector = MSF2SECT(btoi(time[0]), btoi(time[1]), btoi(time[2]));
+ long ret;
if (cdHandle == NULL) {
return -1;
}
}
- cdimg_read_func(cdHandle, 0, cdbuffer, sector);
+ ret = cdimg_read_func(cdHandle, 0, cdbuffer, sector);
+ if (ret < 0)
+ return -1;
if (subHandle != NULL) {
fseek(subHandle, sector * SUB_FRAMESIZE, SEEK_SET);