diff options
author | Dimitry Andric <dim@FreeBSD.org> | 2017-12-18 20:12:36 +0000 |
---|---|---|
committer | Dimitry Andric <dim@FreeBSD.org> | 2017-12-18 20:12:36 +0000 |
commit | ef5d0b5e97ec8e6fa395d377b09aa7755e345b4f (patch) | |
tree | 27916256fdeeb57d10d2f3d6948be5d71a703215 /source/Core/DumpDataExtractor.cpp | |
parent | 76e0736e7fcfeb179779e49c05604464b1ccd704 (diff) | |
download | src-ef5d0b5e97ec8e6fa395d377b09aa7755e345b4f.tar.gz src-ef5d0b5e97ec8e6fa395d377b09aa7755e345b4f.zip |
Vendor import of lldb trunk r321017:vendor/lldb/lldb-trunk-r321017
Notes
Notes:
svn path=/vendor/lldb/dist/; revision=326949
svn path=/vendor/lldb/lldb-trunk-r321017/; revision=326950; tag=vendor/lldb/lldb-trunk-r321017
Diffstat (limited to 'source/Core/DumpDataExtractor.cpp')
-rw-r--r-- | source/Core/DumpDataExtractor.cpp | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/source/Core/DumpDataExtractor.cpp b/source/Core/DumpDataExtractor.cpp index c2a9115c3068..e564e86478fc 100644 --- a/source/Core/DumpDataExtractor.cpp +++ b/source/Core/DumpDataExtractor.cpp @@ -272,6 +272,13 @@ lldb::offset_t lldb_private::DumpDataExtractor( case eFormatChar: case eFormatCharPrintable: case eFormatCharArray: { + // Reject invalid item_byte_size. + if (item_byte_size > 8) { + s->Printf("error: unsupported byte size (%" PRIu64 ") for char format", + (uint64_t)item_byte_size); + return offset; + } + // If we are only printing one character surround it with single // quotes if (item_count == 1 && item_format == eFormatChar) |