mirror of
https://gitee.com/anod/open_agb_firm.git
synced 2025-05-07 22:34:12 +08:00
定位到原因,尝试fix
This commit is contained in:
parent
1a22fcc816
commit
3473dd2008
@ -389,6 +389,7 @@ static Result loadGbaRom(const char *const path, u32 *const romSizeOut)
|
||||
u32 read;
|
||||
while((res = fRead(f, ptr, 0x100000u, &read)) == RES_OK && read == 0x100000u)
|
||||
ptr += 0x100000u;
|
||||
fClose(f);
|
||||
|
||||
// use the gbaatm cheat
|
||||
char gamecode[5];
|
||||
@ -400,11 +401,14 @@ static Result loadGbaRom(const char *const path, u32 *const romSizeOut)
|
||||
debug_printf("cheat res: %s => %d\n", gamecode, err);
|
||||
acl_close_lib();
|
||||
fini_current_cheat();
|
||||
|
||||
*romSizeOut = fixRomPadding(fileSize);
|
||||
}
|
||||
else res = RES_ROM_TOO_BIG;
|
||||
|
||||
fClose(f);
|
||||
else
|
||||
{
|
||||
res = RES_ROM_TOO_BIG;
|
||||
fClose(f);
|
||||
}
|
||||
}
|
||||
|
||||
return res;
|
||||
|
Loading…
x
Reference in New Issue
Block a user