summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--lldb/source/Core/Stream.cpp4
-rw-r--r--lldb/source/Plugins/SymbolFile/DWARF/DWARFLocationList.cpp6
2 files changed, 8 insertions, 2 deletions
diff --git a/lldb/source/Core/Stream.cpp b/lldb/source/Core/Stream.cpp
index 77fc0d53dea..47b794b49bc 100644
--- a/lldb/source/Core/Stream.cpp
+++ b/lldb/source/Core/Stream.cpp
@@ -168,10 +168,12 @@ Stream::Address (uint64_t addr, int addr_size, const char *prefix, const char *s
void
Stream::AddressRange(uint64_t lo_addr, uint64_t hi_addr, int addr_size, const char *prefix, const char *suffix)
{
- if (prefix != NULL)
+ if (prefix && prefix[0])
PutCString (prefix);
Address (lo_addr, addr_size, "[");
Address (hi_addr, addr_size, "-", ")");
+ if (suffix && suffix[0])
+ PutCString (suffix);
}
diff --git a/lldb/source/Plugins/SymbolFile/DWARF/DWARFLocationList.cpp b/lldb/source/Plugins/SymbolFile/DWARF/DWARFLocationList.cpp
index 30a243ea652..ef53eb55121 100644
--- a/lldb/source/Plugins/SymbolFile/DWARF/DWARFLocationList.cpp
+++ b/lldb/source/Plugins/SymbolFile/DWARF/DWARFLocationList.cpp
@@ -34,7 +34,11 @@ DWARFLocationList::Dump(Stream &s, const DWARFCompileUnit* cu, const DataExtract
s.PutCString("\n ");
s.Indent();
- s.AddressRange(start_addr + base_addr, end_addr + base_addr, NULL, ": ");
+ s.AddressRange (start_addr + base_addr,
+ end_addr + base_addr,
+ cu->GetAddressByteSize(),
+ NULL,
+ ": ");
uint32_t loc_length = debug_loc_data.GetU16(&offset);
DataExtractor locationData(debug_loc_data, offset, loc_length);
OpenPOWER on IntegriCloud