diff options
Diffstat (limited to 'lldb/source/API/SBFrame.cpp')
-rw-r--r-- | lldb/source/API/SBFrame.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/lldb/source/API/SBFrame.cpp b/lldb/source/API/SBFrame.cpp index 1845b12cfcd..5500c339dfa 100644 --- a/lldb/source/API/SBFrame.cpp +++ b/lldb/source/API/SBFrame.cpp @@ -52,6 +52,8 @@ #include "lldb/API/SBValue.h" #include "lldb/API/SBVariablesOptions.h" +#include "llvm/Support/PrettyStackTrace.h" + using namespace lldb; using namespace lldb_private; @@ -1288,10 +1290,11 @@ lldb::SBValue SBFrame::EvaluateExpression(const char *expr, if (stop_locker.TryLock(&process->GetRunLock())) { frame = exe_ctx.GetFramePtr(); if (frame) { + std::unique_ptr<llvm::PrettyStackTraceFormat> PST; if (target->GetDisplayExpressionsInCrashlogs()) { StreamString frame_description; frame->DumpUsingSettingsFormat(&frame_description); - Host::SetCrashDescriptionWithFormat( + PST = llvm::make_unique<llvm::PrettyStackTraceFormat>( "SBFrame::EvaluateExpression (expr = \"%s\", fetch_dynamic_value " "= %u) %s", expr, options.GetFetchDynamicValue(), @@ -1301,9 +1304,6 @@ lldb::SBValue SBFrame::EvaluateExpression(const char *expr, exe_results = target->EvaluateExpression(expr, frame, expr_value_sp, options.ref()); expr_result.SetSP(expr_value_sp, options.GetFetchDynamicValue()); - - if (target->GetDisplayExpressionsInCrashlogs()) - Host::SetCrashDescription(nullptr); } else { if (log) log->Printf("SBFrame::EvaluateExpression () => error: could not " |