Merge "vndk-vtable-dumper: Use demangled name of symbol while handling symbol aliasing." into pi-dev

This commit is contained in:
Jayant Chowdhary
2018-05-23 16:29:10 +00:00
committed by Android (Google) Code Review

View File

@@ -329,9 +329,10 @@ SymbolRef ELFSharedObject<ELFT>::matchValueToSymbol(
const std::string ClassName(Vtablep->getDemangledName().substr(pos));
for (const SymbolRef &Symbol : SymVec) {
StringRef SymbolName = UnWrap(Symbol.getName());
if (SymbolName.str().find(ClassName) != std::string::npos)
if (demangle(SymbolName.str()).find(ClassName) != std::string::npos) {
return Symbol;
}
}
// Return the 1st Symbol by default.
return SymVec[0];
}