From 399f1cafa64b9dc15be5b8b48bfd12d5449e5b6e Mon Sep 17 00:00:00 2001 From: Jim Ingham Date: Fri, 5 Nov 2010 19:25:48 +0000 Subject: Added the equivalent of gdb's "unwind-on-signal" to the expression command, and a parameter to control it in ClangUserExpression, and on down to ClangFunction. llvm-svn: 118290 --- lldb/source/Target/Process.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'lldb/source/Target/Process.cpp') diff --git a/lldb/source/Target/Process.cpp b/lldb/source/Target/Process.cpp index fa7ac71c89e..d544a4f61ba 100644 --- a/lldb/source/Target/Process.cpp +++ b/lldb/source/Target/Process.cpp @@ -505,13 +505,13 @@ Process::LoadImage (const FileSpec &image_spec, Error &error) { ExecutionContext exe_ctx; frame_sp->CalculateExecutionContext (exe_ctx); - + bool unwind_on_error = true; StreamString expr; char path[PATH_MAX]; image_spec.GetPath(path, sizeof(path)); expr.Printf("dlopen (\"%s\", 2)", path); const char *prefix = "extern \"C\" void* dlopen (const char *path, int mode);\n"; - lldb::ValueObjectSP result_valobj_sp (ClangUserExpression::Evaluate (exe_ctx, expr.GetData(), prefix)); + lldb::ValueObjectSP result_valobj_sp (ClangUserExpression::Evaluate (exe_ctx, unwind_on_error, expr.GetData(), prefix)); if (result_valobj_sp->GetError().Success()) { Scalar scalar; @@ -571,11 +571,11 @@ Process::UnloadImage (uint32_t image_token) { ExecutionContext exe_ctx; frame_sp->CalculateExecutionContext (exe_ctx); - + bool unwind_on_error = true; StreamString expr; expr.Printf("dlclose ((void *)0x%llx)", image_addr); const char *prefix = "extern \"C\" int dlclose(void* handle);\n"; - lldb::ValueObjectSP result_valobj_sp (ClangUserExpression::Evaluate (exe_ctx, expr.GetData(), prefix)); + lldb::ValueObjectSP result_valobj_sp (ClangUserExpression::Evaluate (exe_ctx, unwind_on_error, expr.GetData(), prefix)); if (result_valobj_sp->GetError().Success()) { Scalar scalar; -- cgit v1.2.3