mirror of
https://github.com/dborth/vbagx.git
synced 2024-11-22 10:39:18 +01:00
code tidy
This commit is contained in:
parent
46efa8c104
commit
607d5d0f97
@ -929,19 +929,7 @@ bool LoadGBROM()
|
||||
}
|
||||
else
|
||||
{
|
||||
int device = GCSettings.LoadMethod;
|
||||
|
||||
switch (device)
|
||||
{
|
||||
case DEVICE_SD:
|
||||
case DEVICE_USB:
|
||||
case DEVICE_SMB:
|
||||
gbRomSize = LoadSzFile(szpath, (unsigned char *)gbRom);
|
||||
break;
|
||||
case DEVICE_DVD:
|
||||
gbRomSize = SzExtractFile(browserList[browser.selIndex].filenum, (unsigned char *)gbRom);
|
||||
break;
|
||||
}
|
||||
gbRomSize = LoadSzFile(szpath, (unsigned char *)gbRom);
|
||||
}
|
||||
|
||||
if(gbRomSize <= 0)
|
||||
|
@ -268,7 +268,7 @@ int VMCPULoadROM()
|
||||
char filepath[MAXPATHLEN];
|
||||
|
||||
if(!MakeFilePath(filepath, FILE_ROM))
|
||||
return false;
|
||||
return 0;
|
||||
|
||||
// loading compressed files via VM is not supported
|
||||
if(!utilIsGBAImage(filepath))
|
||||
@ -304,9 +304,8 @@ int VMCPULoadROM()
|
||||
return 0;
|
||||
}
|
||||
|
||||
struct stat fileinfo;
|
||||
fstat(romfile->_file, &fileinfo);
|
||||
GBAROMSize = fileinfo.st_size;
|
||||
fseeko(romfile,0,SEEK_END);
|
||||
GBAROMSize = ftello(romfile);
|
||||
|
||||
vmpageno = 0;
|
||||
vmpage[0].pageptr = rombase;
|
||||
|
Loading…
Reference in New Issue
Block a user