mirror of
https://github.com/wiiu-env/HBLInstallerWrapper.git
synced 2024-11-21 21:49:16 +01:00
Simplify pre-setup. (#2)
* Simplify pre-setup. Signed-off-by: Thomas Rohloff <v10lator@myway.de> Co-authored-by: Maschell <Maschell@gmx.de>
This commit is contained in:
parent
dca014b2a5
commit
8cb5eb23fe
@ -145,21 +145,16 @@ static void InstallPatches() {
|
||||
OsSpecifics osSpecificFunctions;
|
||||
memset(&osSpecificFunctions, 0, sizeof(OsSpecifics));
|
||||
|
||||
unsigned int bufferU32;
|
||||
/* Pre-setup a few options to defined values */
|
||||
bufferU32 = 550;
|
||||
memcpy((void *) &OS_FIRMWARE, &bufferU32, sizeof(bufferU32));
|
||||
bufferU32 = 0xDEADC0DE;
|
||||
memcpy((void *) &MAIN_ENTRY_ADDR, &bufferU32, sizeof(bufferU32));
|
||||
memcpy((void *) &ELF_DATA_ADDR, &bufferU32, sizeof(bufferU32));
|
||||
bufferU32 = 0;
|
||||
memcpy((void *) &ELF_DATA_SIZE, &bufferU32, sizeof(bufferU32));
|
||||
memcpy((void *) &HBL_CHANNEL, &bufferU32, sizeof(bufferU32));
|
||||
|
||||
// If we install the sd_loader but don't have any homebrew loaded some applications won't start.
|
||||
// We load a stub that just opens the real app and opens the hbl when opening the mii maker.
|
||||
memcpy((void *) 0x00802000, homebrew_stub, sizeof(homebrew_stub));
|
||||
|
||||
/* Pre-setup a few options to defined values */
|
||||
OS_FIRMWARE = 550;
|
||||
MAIN_ENTRY_ADDR = 0x00802000;
|
||||
ELF_DATA_ADDR = 0xDEADC0DE;
|
||||
ELF_DATA_SIZE = 0;
|
||||
HBL_CHANNEL = 0;
|
||||
|
||||
osSpecificFunctions.addr_OSDynLoad_Acquire = (unsigned int) OSDynLoad_Acquire;
|
||||
osSpecificFunctions.addr_OSDynLoad_FindExport = (unsigned int) OSDynLoad_FindExport;
|
||||
|
Loading…
Reference in New Issue
Block a user