diff options
Diffstat (limited to 'lldb/source/API')
| -rw-r--r-- | lldb/source/API/SBValue.cpp | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/lldb/source/API/SBValue.cpp b/lldb/source/API/SBValue.cpp index 876670a510c..654336db8c5 100644 --- a/lldb/source/API/SBValue.cpp +++ b/lldb/source/API/SBValue.cpp @@ -392,8 +392,11 @@ SBValue::CreateValueFromExpression (const char *name, const char* expression) true, // keep in memory eNoDynamicValues, result_valobj_sp); - result_valobj_sp->SetName(ConstString(name)); - result = SBValue(result_valobj_sp); + if (result_valobj_sp) + { + result_valobj_sp->SetName(ConstString(name)); + result = SBValue(result_valobj_sp); + } } LogSP log(lldb_private::GetLogIfAllCategoriesSet (LIBLLDB_LOG_API)); if (log) |

