mirror of
https://github.com/yuzu-emu/breakpad.git
synced 2025-01-23 03:51:09 +00:00
Do not read CFI section when not outputing CFI information.
This revert revision 1182 and fix setting the module load address whether CFI information is needed or not. R=mark@chromium.org Review URL: https://breakpad.appspot.com/641002 git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@1243 4c0a9323-5329-0410-9bdc-e9ce6186880e
This commit is contained in:
parent
08ce8e35eb
commit
d9d0a61f97
|
@ -406,12 +406,14 @@ bool DumpSymbols::LoadCommandDumper::SegmentCommand(const Segment &segment) {
|
||||||
|
|
||||||
if (segment.name == "__TEXT") {
|
if (segment.name == "__TEXT") {
|
||||||
module_->SetLoadAddress(segment.vmaddr);
|
module_->SetLoadAddress(segment.vmaddr);
|
||||||
|
if (symbol_data_ != NO_CFI) {
|
||||||
mach_o::SectionMap::const_iterator eh_frame =
|
mach_o::SectionMap::const_iterator eh_frame =
|
||||||
section_map.find("__eh_frame");
|
section_map.find("__eh_frame");
|
||||||
if (eh_frame != section_map.end()) {
|
if (eh_frame != section_map.end()) {
|
||||||
// If there is a problem reading this, don't treat it as a fatal error.
|
// If there is a problem reading this, don't treat it as a fatal error.
|
||||||
dumper_.ReadCFI(module_, reader_, eh_frame->second, true);
|
dumper_.ReadCFI(module_, reader_, eh_frame->second, true);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -422,6 +424,7 @@ bool DumpSymbols::LoadCommandDumper::SegmentCommand(const Segment &segment) {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
if (symbol_data_ != NO_CFI) {
|
||||||
mach_o::SectionMap::const_iterator debug_frame
|
mach_o::SectionMap::const_iterator debug_frame
|
||||||
= section_map.find("__debug_frame");
|
= section_map.find("__debug_frame");
|
||||||
if (debug_frame != section_map.end()) {
|
if (debug_frame != section_map.end()) {
|
||||||
|
@ -429,6 +432,7 @@ bool DumpSymbols::LoadCommandDumper::SegmentCommand(const Segment &segment) {
|
||||||
dumper_.ReadCFI(module_, reader_, debug_frame->second, false);
|
dumper_.ReadCFI(module_, reader_, debug_frame->second, false);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue