mirror of
https://github.com/wiiu-env/WiiUPluginSystem.git
synced 2024-12-25 17:41:56 +01:00
Fix a crash that could happen due worng relocations. The address in the used bl is SINGNED. This mean for everything above 0x01FFFFFC we need to use the big jump.
This commit is contained in:
parent
b1d89c9d4d
commit
77288a2365
@ -173,7 +173,7 @@ bool DynamicLinkingHelper::fillRelocations(std::vector<dyn_linking_relocation_en
|
|||||||
|
|
||||||
DEBUG_FUNCTION_LINE("Resolving relocation to %s\n",functionEntry->functionName);
|
DEBUG_FUNCTION_LINE("Resolving relocation to %s\n",functionEntry->functionName);
|
||||||
|
|
||||||
if(!curEntry->importEntry->isData && (uint32_t) functionEntry->address > 0x04000000) {
|
if(!curEntry->importEntry->isData && (uint32_t) functionEntry->address > 0x01FFFFC) {
|
||||||
ElfTools::elfLinkOne(curEntry->type, curEntry->offset, curEntry->addend, curEntry->destination, (uint32_t) functionEntry->big_jump);
|
ElfTools::elfLinkOne(curEntry->type, curEntry->offset, curEntry->addend, curEntry->destination, (uint32_t) functionEntry->big_jump);
|
||||||
} else {
|
} else {
|
||||||
ElfTools::elfLinkOne(curEntry->type, curEntry->offset, curEntry->addend, curEntry->destination, (uint32_t) functionEntry->address);
|
ElfTools::elfLinkOne(curEntry->type, curEntry->offset, curEntry->addend, curEntry->destination, (uint32_t) functionEntry->address);
|
||||||
|
Loading…
Reference in New Issue
Block a user