diff options
Diffstat (limited to 'lldb/source/API/SBValue.cpp')
| -rw-r--r-- | lldb/source/API/SBValue.cpp | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/lldb/source/API/SBValue.cpp b/lldb/source/API/SBValue.cpp index b72c8f181b8..96182e37428 100644 --- a/lldb/source/API/SBValue.cpp +++ b/lldb/source/API/SBValue.cpp @@ -377,7 +377,10 @@ SBValue::CreateChildAtOffset (const char *name, uint32_t offset, SBType type) lldb::SBValue SBValue::Cast (SBType type) { - return CreateChildAtOffset(m_opaque_sp->GetName().GetCString(), 0, type); + lldb::SBValue sb_value; + if (m_opaque_sp) + sb_value = CreateChildAtOffset(m_opaque_sp->GetName().GetCString(), 0, type); + return sb_value; } lldb::SBValue |

