X-Git-Url: https://notaz.gp2x.de/cgi-bin/gitweb.cgi?p=pcsx_rearmed.git;a=blobdiff_plain;f=libpcsxcore%2Fppf.c;h=6fcd5bc1094f837dd4eba1a87c5b417800da21f1;hp=268ed1cb8a3d6de8b23e774e91d1efb827495409;hb=ad418c19cd4ca9a80820593609b786c6993b2eda;hpb=ae4e7dc990c2acd9cb208dd8fb02f1c96f915b7c diff --git a/libpcsxcore/ppf.c b/libpcsxcore/ppf.c index 268ed1cb..6fcd5bc1 100644 --- a/libpcsxcore/ppf.c +++ b/libpcsxcore/ppf.c @@ -190,6 +190,8 @@ void BuildPPFCache() { FreePPFCache(); + if (CdromId[0] == '\0') return; + // Generate filename in the format of SLUS_123.45 buffer[0] = toupper(CdromId[0]); buffer[1] = toupper(CdromId[1]); @@ -335,7 +337,7 @@ void BuildPPFCache() { unsigned char *sbi_sectors; int LoadSBI(const char *fname, int sector_count) { - char buffer[16], sbifile[MAXPATHLEN]; + char buffer[16]; FILE *sbihandle; u8 sbitime[3]; int s; @@ -344,7 +346,6 @@ int LoadSBI(const char *fname, int sector_count) { if (sbihandle == NULL) return -1; -if (sbi_sectors != NULL) printf("sbi_sectors?\n"); sbi_sectors = calloc(1, sector_count / 8); if (sbi_sectors == NULL) return -1;