[llvm-reaobj] Display COFF-specific sections/tables only if the object is COFF.

Just skip them otherwise.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@243086 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Davide Italiano 2015-07-24 02:14:20 +00:00
parent fc561accb7
commit c46ea19bd3

View File

@ -302,15 +302,16 @@ static void dumpObject(const ObjectFile *Obj) {
if (opts::MipsReginfo) if (opts::MipsReginfo)
Dumper->printMipsReginfo(); Dumper->printMipsReginfo();
} }
if (opts::COFFImports) if (Obj->isCOFF()) {
Dumper->printCOFFImports(); if (opts::COFFImports)
if (opts::COFFExports) Dumper->printCOFFImports();
Dumper->printCOFFExports(); if (opts::COFFExports)
if (opts::COFFDirectives) Dumper->printCOFFExports();
Dumper->printCOFFDirectives(); if (opts::COFFDirectives)
if (opts::COFFBaseRelocs) Dumper->printCOFFDirectives();
Dumper->printCOFFBaseReloc(); if (opts::COFFBaseRelocs)
Dumper->printCOFFBaseReloc();
}
if (opts::PrintStackMap) if (opts::PrintStackMap)
Dumper->printStackMap(); Dumper->printStackMap();
} }