mirror of
https://github.com/wiiu-env/wut.git
synced 2025-01-22 11:41:14 +01:00
Fix corner case with findSymbol in elf2rpl
This commit is contained in:
parent
1ff6658dcc
commit
2574e29958
@ -89,6 +89,12 @@ struct InputSection
|
|||||||
static ElfFile::Symbol *
|
static ElfFile::Symbol *
|
||||||
findSymbol(ElfFile &file, uint32_t address)
|
findSymbol(ElfFile &file, uint32_t address)
|
||||||
{
|
{
|
||||||
|
for (auto &symbol : file.symbols) {
|
||||||
|
if (symbol->address == address && symbol->type != elf::STT_NOTYPE) {
|
||||||
|
return symbol.get();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
for (auto &symbol : file.symbols) {
|
for (auto &symbol : file.symbols) {
|
||||||
if (symbol->address == address) {
|
if (symbol->address == address) {
|
||||||
return symbol.get();
|
return symbol.get();
|
||||||
|
Loading…
x
Reference in New Issue
Block a user