diff --git a/lldb/source/Plugins/SymbolFile/DWARF/DWARFDeclContext.h b/lldb/source/Plugins/SymbolFile/DWARF/DWARFDeclContext.h index 85c97f1c68f2..accd3446317a 100644 --- a/lldb/source/Plugins/SymbolFile/DWARF/DWARFDeclContext.h +++ b/lldb/source/Plugins/SymbolFile/DWARF/DWARFDeclContext.h @@ -46,9 +46,11 @@ public: bool NameMatches (const Entry& rhs) const { - if (name && rhs.name) + if (name == rhs.name) + return true; + else if (name && rhs.name) return strcmp(name, rhs.name) == 0; - return name == NULL && rhs.name == NULL; + return false; } // Test operator