diff --git a/source/emunand.c b/source/emunand.c index 9cb50e7..b1dd5ba 100644 --- a/source/emunand.c +++ b/source/emunand.c @@ -52,7 +52,7 @@ void *getMPU(void *pos, u32 size){ return memsearch(pos, pattern, size, 4); } -u8 *getEmuCode(void *pos, u32 size, u8 *proc9Offset){ +void *getEmuCode(void *pos, u32 size, u8 *proc9Offset){ const unsigned char pattern[] = {0x00, 0xFF, 0xFF, 0xFF}; //Looking for the last free space before Process9 diff --git a/source/emunand.h b/source/emunand.h index 4ec8050..b20705d 100644 --- a/source/emunand.h +++ b/source/emunand.h @@ -14,4 +14,4 @@ void getEmunandSect(u32 *off, u32 *head, u32 emuNAND); u32 getSDMMC(void *pos, u32 size); void getEmuRW(void *pos, u32 size, u32 *readOff, u32 *writeOff); void *getMPU(void *pos, u32 size); -u8 *getEmuCode(void *pos, u32 size, u8 *proc9Offset); \ No newline at end of file +void *getEmuCode(void *pos, u32 size, u8 *proc9Offset); \ No newline at end of file diff --git a/source/firm.c b/source/firm.c index bece046..ce59280 100755 --- a/source/firm.c +++ b/source/firm.c @@ -166,7 +166,7 @@ static void loadEmu(u8 *proc9Offset){ emuRead, emuWrite; - u8 *emuCodeOffset = getEmuCode(arm9Section, section[2].size, proc9Offset); + void *emuCodeOffset = getEmuCode(arm9Section, section[2].size, proc9Offset); memcpy(emuCodeOffset, emunand, emunand_size); //Look for emuNAND @@ -215,7 +215,7 @@ void patchFirm(void){ //Patch FIRM reboots, not on 9.0 FIRM as it breaks firmlaunchhax if(mode){ //Read reboot code from SD - u8 *rebootOffset = getReboot(arm9Section, section[2].size); + void *rebootOffset = getReboot(arm9Section, section[2].size); memcpy(rebootOffset, reboot, reboot_size); //Calculate the fOpen offset and put it in the right location diff --git a/source/patches.c b/source/patches.c index e81fdf3..bf7dfa6 100644 --- a/source/patches.c +++ b/source/patches.c @@ -42,7 +42,7 @@ void getSignatures(void *pos, u32 size, u32 *off, u32 *off2){ *off2 = (u32)memsearch(pos, pattern2, size, 4) - 1; } -u8 *getReboot(void *pos, u32 size){ +void *getReboot(void *pos, u32 size){ //Look for FIRM reboot code const unsigned char pattern[] = {0xDE, 0x1F, 0x8D, 0xE2}; diff --git a/source/patches.h b/source/patches.h index 09d52d1..9181c29 100644 --- a/source/patches.h +++ b/source/patches.h @@ -22,6 +22,6 @@ const u8 writeBlock[4]; **************************************************/ u8 *getProc9(void *pos, u32 size); void getSignatures(void *pos, u32 size, u32 *off, u32 *off2); -u8 *getReboot(void *pos, u32 size); +void *getReboot(void *pos, u32 size); u32 getfOpen(void *pos, u32 size, u8 *proc9Offset); void *getFirmWrite(void *pos, u32 size); \ No newline at end of file