[Lldb-commits] [lldb] [lldb][core] Fix getting summary of a variable pointing to r/o memory (PR #139196)
Pavel Labath via lldb-commits
lldb-commits at lists.llvm.org
Mon May 12 03:16:09 PDT 2025
================
@@ -734,15 +734,22 @@ size_t ValueObject::GetPointeeData(DataExtractor &data, uint32_t item_idx,
} break;
case eAddressTypeLoad: {
ExecutionContext exe_ctx(GetExecutionContextRef());
- Process *process = exe_ctx.GetProcessPtr();
- if (process) {
- heap_buf_ptr->SetByteSize(bytes);
- size_t bytes_read = process->ReadMemory(
+ heap_buf_ptr->SetByteSize(bytes);
+ size_t bytes_read = 0;
+ if (Process *process = exe_ctx.GetProcessPtr();
+ process && process->IsLiveDebugSession()) {
----------------
labath wrote:
I'd like to avoid special casing core files. Can we just call the target version all the time?
https://github.com/llvm/llvm-project/pull/139196
More information about the lldb-commits
mailing list