[llvm] r180006 - llvm-readobj: Check for null section pointer
Nico Rieck
nico.rieck at gmail.com
Mon Apr 22 01:34:59 PDT 2013
Author: nrieck
Date: Mon Apr 22 03:34:59 2013
New Revision: 180006
URL: http://llvm.org/viewvc/llvm-project?rev=180006&view=rev
Log:
llvm-readobj: Check for null section pointer
Modified:
llvm/trunk/tools/llvm-readobj/COFFDumper.cpp
Modified: llvm/trunk/tools/llvm-readobj/COFFDumper.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/tools/llvm-readobj/COFFDumper.cpp?rev=180006&r1=180005&r2=180006&view=diff
==============================================================================
--- llvm/trunk/tools/llvm-readobj/COFFDumper.cpp (original)
+++ llvm/trunk/tools/llvm-readobj/COFFDumper.cpp Mon Apr 22 03:34:59 2013
@@ -799,7 +799,7 @@ void COFFDumper::printSymbol(symbol_iter
W.printEnum("Selection", Aux->Selection, makeArrayRef(ImageCOMDATSelect));
W.printBinary("Unused", makeArrayRef(Aux->Unused));
- if (Section->Characteristics & COFF::IMAGE_SCN_LNK_COMDAT
+ if (Section && Section->Characteristics & COFF::IMAGE_SCN_LNK_COMDAT
&& Aux->Selection == COFF::IMAGE_COMDAT_SELECT_ASSOCIATIVE) {
const coff_section *Assoc;
StringRef AssocName;
More information about the llvm-commits
mailing list