summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJason Molenda <jmolenda@apple.com>2011-11-08 03:52:17 +0000
committerJason Molenda <jmolenda@apple.com>2011-11-08 03:52:17 +0000
commite519824641e2d42f2387c18a6de957dc6b2910d7 (patch)
treeea4c6a7b44fb4139447124e248e57c81a363bbd1
parentd8d583f7667f01bee96eaeafe79f03b537ac2f9b (diff)
downloadbcm5719-llvm-e519824641e2d42f2387c18a6de957dc6b2910d7.tar.gz
bcm5719-llvm-e519824641e2d42f2387c18a6de957dc6b2910d7.zip
Bitfields in uint8_t's will have format eFormatChar and DataExtractor::Dump
doesn't handle bitfields in eFormatChar's correctly, only eFormatUnsigned. Fix DataExtractor::Dump to dump the bitfield eFormatChars correctly. llvm-svn: 144069
-rw-r--r--lldb/source/Core/DataExtractor.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/lldb/source/Core/DataExtractor.cpp b/lldb/source/Core/DataExtractor.cpp
index a232c0a66fd..9901f67881b 100644
--- a/lldb/source/Core/DataExtractor.cpp
+++ b/lldb/source/Core/DataExtractor.cpp
@@ -1440,6 +1440,9 @@ DataExtractor::Dump (Stream *s,
case eFormatChar:
case eFormatCharPrintable:
case eFormatCharArray:
+ if (item_bit_size < 8)
+ s->Printf ("%llu", GetMaxU64Bitfield(&offset, item_byte_size, item_bit_size, item_bit_offset));
+ else
{
// If we are only printing one character surround it with single
// quotes
OpenPOWER on IntegriCloud