Skip to content

Commit f43b8cc

Browse files
committed
[lldb] Fix use of null shared pointer (#10708)
(cherry-picked from commit 9765245)
1 parent 92742be commit f43b8cc

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

lldb/source/Plugins/Language/Swift/SwiftFormatters.cpp

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1139,8 +1139,10 @@ class CheckedContinuationSyntheticFrontEnd : public SyntheticChildrenFrontEnd {
11391139
m_task_sp = ValueObject::CreateValueObjectFromAddress(
11401140
"task", task_addr, m_backend.GetExecutionContextRef(),
11411141
m_task_type, false);
1142-
if (auto synthetic_sp = m_task_sp->GetSyntheticValue())
1143-
m_task_sp = synthetic_sp;
1142+
1143+
if (m_task_sp)
1144+
if (auto synthetic_sp = m_task_sp->GetSyntheticValue())
1145+
m_task_sp = synthetic_sp;
11441146
return ChildCacheState::eRefetch;
11451147
}
11461148

0 commit comments

Comments
 (0)