[Lldb-commits] [lldb] r284114 - [lldb] Improve identification of Linux core dumps. Fix for bug #30485.
Richard Chamberlain via lldb-commits
lldb-commits at lists.llvm.org
Thu Oct 13 05:11:04 PDT 2016
Author: rnchamberlain
Date: Thu Oct 13 07:11:00 2016
New Revision: 284114
URL: http://llvm.org/viewvc/llvm-project?rev=284114&view=rev
Log:
[lldb] Improve identification of Linux core dumps. Fix for bug #30485.
Summary:
ObjectFileELF::RefineModuleDetailsFromNote() identifies Linux core dumps by searching for
library paths starting with /lib/x86_64-linux-gnu or /lib/i386-linux-gnu. This change widens the
test to allow for linux installations which have addition directories in the path.
Reviewers: ted, hhellyer, clayborg
Subscribers: lldb-commits
Differential Revision: https://reviews.llvm.org/D25179
Modified:
lldb/trunk/source/Plugins/ObjectFile/ELF/ObjectFileELF.cpp
Modified: lldb/trunk/source/Plugins/ObjectFile/ELF/ObjectFileELF.cpp
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/source/Plugins/ObjectFile/ELF/ObjectFileELF.cpp?rev=284114&r1=284113&r2=284114&view=diff
==============================================================================
--- lldb/trunk/source/Plugins/ObjectFile/ELF/ObjectFileELF.cpp (original)
+++ lldb/trunk/source/Plugins/ObjectFile/ELF/ObjectFileELF.cpp Thu Oct 13 07:11:00 2016
@@ -1405,8 +1405,7 @@ ObjectFileELF::RefineModuleDetailsFromNo
return error;
}
llvm::StringRef path(cstr);
- if (path.startswith("/lib/x86_64-linux-gnu") ||
- path.startswith("/lib/i386-linux-gnu")) {
+ if (path.contains("/lib/x86_64-linux-gnu") || path.contains("/lib/i386-linux-gnu")) {
arch_spec.GetTriple().setOS(llvm::Triple::OSType::Linux);
break;
}
More information about the lldb-commits
mailing list