<div dir="ltr"><div class="gmail_extra"><div class="gmail_quote">On Wed, Oct 15, 2014 at 10:07 AM, Jason Molenda <span dir="ltr"><<a href="mailto:jmolenda@apple.com" target="_blank">jmolenda@apple.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Author: jmolenda<br>
Date: Tue Oct 14 22:07:39 2014<br>
New Revision: 219771<br>
<br>
URL: <a href="http://llvm.org/viewvc/llvm-project?rev=219771&view=rev" target="_blank">http://llvm.org/viewvc/llvm-project?rev=219771&view=rev</a><br>
Log:<br>
Make sure local var cu is non-NULL before dereferencing.<br>
(it was checked for NULL-ness in some places, not in others)<br>
clang static analyzer fixit.<br>
<br>
Modified:<br>
    lldb/trunk/source/Plugins/SymbolFile/DWARF/DWARFDebugInfo.cpp<br>
<br>
Modified: lldb/trunk/source/Plugins/SymbolFile/DWARF/DWARFDebugInfo.cpp<br>
URL: <a href="http://llvm.org/viewvc/llvm-project/lldb/trunk/source/Plugins/SymbolFile/DWARF/DWARFDebugInfo.cpp?rev=219771&r1=219770&r2=219771&view=diff" target="_blank">http://llvm.org/viewvc/llvm-project/lldb/trunk/source/Plugins/SymbolFile/DWARF/DWARFDebugInfo.cpp?rev=219771&r1=219770&r2=219771&view=diff</a><br>
==============================================================================<br>
--- lldb/trunk/source/Plugins/SymbolFile/DWARF/DWARFDebugInfo.cpp (original)<br>
+++ lldb/trunk/source/Plugins/SymbolFile/DWARF/DWARFDebugInfo.cpp Tue Oct 14 22:07:39 2014<br>
@@ -555,7 +555,8 @@ static dw_offset_t DumpCallback<br>
         if (dumpInfo->die_offset == DW_INVALID_OFFSET)<br>
         {<br>
             // We are dumping everything<br>
-            cu->Dump(s);<br>
+            if (cu)<br>
+                cu->Dump(s);<br>
             return cu->GetFirstDIEOffset(); // Return true to parse all DIEs in this Compile Unit<br>
         }<br>
         else<br></blockquote><div><br></div><div>This one doesn't make sense ... if you check it for cu->Dump, but the very next line outside of the if statement is the return cu->GetFirstDIEOffset() ...</div><div><br></div><div> - Bruce</div><div> </div></div></div></div>