diff options
author | Greg Clayton <gclayton@apple.com> | 2013-04-29 17:25:54 +0000 |
---|---|---|
committer | Greg Clayton <gclayton@apple.com> | 2013-04-29 17:25:54 +0000 |
commit | b5ad4ec7a31206227b1cd657dd41b21cc6afc98e (patch) | |
tree | 68f35ccdff9e1410bca21aeb2e216fa91d45a19f /lldb/source/Plugins/ObjectFile/Mach-O/ObjectFileMachO.cpp | |
parent | f1f1c626e7fcd3db60641be223308390de288a41 (diff) | |
download | bcm5719-llvm-b5ad4ec7a31206227b1cd657dd41b21cc6afc98e.tar.gz bcm5719-llvm-b5ad4ec7a31206227b1cd657dd41b21cc6afc98e.zip |
Cleanup logging to use the new "std::string FileSpec::GetPath()" function. Also added a similar function for modules:
std::string
Module::GetSpecificationDescription () const;
This returns the module as "/usr/lib/libfoo.dylib" for normal files (calls "std::string FileSpec::GetPath()" on m_file) but it also might include the object name in case the module is for a .o file in a BSD archive ("/usr/lib/libfoo.a(bar.o)"). Cleaned up necessary logging code to use it.
llvm-svn: 180717
Diffstat (limited to 'lldb/source/Plugins/ObjectFile/Mach-O/ObjectFileMachO.cpp')
-rw-r--r-- | lldb/source/Plugins/ObjectFile/Mach-O/ObjectFileMachO.cpp | 10 |
1 files changed, 4 insertions, 6 deletions
diff --git a/lldb/source/Plugins/ObjectFile/Mach-O/ObjectFileMachO.cpp b/lldb/source/Plugins/ObjectFile/Mach-O/ObjectFileMachO.cpp index 7bd6020f1e6..b94ebca297d 100644 --- a/lldb/source/Plugins/ObjectFile/Mach-O/ObjectFileMachO.cpp +++ b/lldb/source/Plugins/ObjectFile/Mach-O/ObjectFileMachO.cpp @@ -1916,11 +1916,10 @@ ObjectFileMachO::ParseSymtab (bool minimize) // string values should have an offset zero which points // to an empty C-string Host::SystemLog (Host::eSystemLogError, - "error: DSC unmapped local symbol[%u] has invalid string table offset 0x%x in %s/%s, ignoring symbol\n", + "error: DSC unmapped local symbol[%u] has invalid string table offset 0x%x in %s, ignoring symbol\n", entry_index, nlist.n_strx, - module_sp->GetFileSpec().GetDirectory().GetCString(), - module_sp->GetFileSpec().GetFilename().GetCString()); + module_sp->GetFileSpec().GetPath().c_str()); continue; } if (symbol_name[0] == '\0') @@ -2653,11 +2652,10 @@ ObjectFileMachO::ParseSymtab (bool minimize) // string values should have an offset zero which points // to an empty C-string Host::SystemLog (Host::eSystemLogError, - "error: symbol[%u] has invalid string table offset 0x%x in %s/%s, ignoring symbol\n", + "error: symbol[%u] has invalid string table offset 0x%x in %s, ignoring symbol\n", nlist_idx, nlist.n_strx, - module_sp->GetFileSpec().GetDirectory().GetCString(), - module_sp->GetFileSpec().GetFilename().GetCString()); + module_sp->GetFileSpec().GetPath().c_str()); continue; } if (symbol_name[0] == '\0') |