[Lldb-commits] [PATCH] D115073: Modify DataEncoder to be able to encode data in an object owned buffer.
Greg Clayton via Phabricator via lldb-commits
lldb-commits at lists.llvm.org
Mon Dec 6 11:02:06 PST 2021
clayborg added inline comments.
================
Comment at: lldb/source/Expression/DWARFExpression.cpp:465
std::unique_ptr<DataBufferHeap> head_data_up(
new DataBufferHeap(m_data.GetDataStart(), m_data.GetByteSize()));
----------------
That would crash the program. The data here is coming from the DWARF from a mmap'ed read only file. We can't modify the data, and thus this is why we make a copy in the first place: so we can modify the DWARF data and fixup the address info.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D115073/new/
https://reviews.llvm.org/D115073
More information about the lldb-commits
mailing list