[Lldb-commits] [lldb] [lldb] Fix variable access in old SBFrames after inferior function calls (PR #178823)
Adrian Prantl via lldb-commits
lldb-commits at lists.llvm.org
Fri Jan 30 16:48:46 PST 2026
================
@@ -641,21 +641,23 @@ lldb::ThreadSP ExecutionContextRef::GetThreadSP() const {
}
lldb::StackFrameSP ExecutionContextRef::GetFrameSP() const {
- if (m_stack_id.IsValid()) {
- // Try the remembered frame list first to avoid circular dependencies
- // during frame provider initialization.
- if (auto frame_list_sp = m_frame_list_wp.lock()) {
+ lldb::ThreadSP thread_sp(GetThreadSP());
+ if (!thread_sp || !m_stack_id.IsValid())
+ return lldb::StackFrameSP();
+
+ // Try the remembered frame list first to avoid circular dependencies
+ // during frame provider initialization.
+ if (m_frame_list_id) {
----------------
adrian-prantl wrote:
Does that mean 0 is a special value? Maybe you can document that in the header.
https://github.com/llvm/llvm-project/pull/178823
More information about the lldb-commits
mailing list