mirror of
https://github.com/yuzu-emu/breakpad.git
synced 2025-09-14 01:57:03 +00:00
Linux: Skip sections of type SHT_NOBITS when loading symbols.
Review URL: http://breakpad.appspot.com/120001 git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@620 4c0a9323-5329-0410-9bdc-e9ce6186880e
This commit is contained in:
parent
e193098543
commit
7fbd77715f
|
@ -118,9 +118,16 @@ static const ElfW(Shdr) *FindSectionByName(const char *name,
|
||||||
const char *section_name =
|
const char *section_name =
|
||||||
reinterpret_cast<char*>(section_names->sh_offset + sections[i].sh_name);
|
reinterpret_cast<char*>(section_names->sh_offset + sections[i].sh_name);
|
||||||
if (names_end - section_name >= name_len + 1 &&
|
if (names_end - section_name >= name_len + 1 &&
|
||||||
strcmp(name, section_name) == 0)
|
strcmp(name, section_name) == 0) {
|
||||||
|
if (sections[i].sh_type == SHT_NOBITS) {
|
||||||
|
fprintf(stderr,
|
||||||
|
"Section %s found, but ignored because type=SHT_NOBITS.\n",
|
||||||
|
name);
|
||||||
|
return NULL;
|
||||||
|
}
|
||||||
return sections + i;
|
return sections + i;
|
||||||
}
|
}
|
||||||
|
}
|
||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue