diff options
| author | Jim Ingham <jingham@apple.com> | 2014-06-25 02:32:56 +0000 |
|---|---|---|
| committer | Jim Ingham <jingham@apple.com> | 2014-06-25 02:32:56 +0000 |
| commit | 106d02866d4d54b09c08e6a12915dba58e709294 (patch) | |
| tree | d495af8b9b7f1823c685bc4ff2ce2a9a0289b5b9 /lldb/source/Target/Target.cpp | |
| parent | ab8d0a0dd514e8313f39e3f09482468577ffe144 (diff) | |
| download | bcm5719-llvm-106d02866d4d54b09c08e6a12915dba58e709294.tar.gz bcm5719-llvm-106d02866d4d54b09c08e6a12915dba58e709294.zip | |
Added an option to turn OFF the "detach on error" behavior that was added
to debugserver when launching processes.
<rdar://problem/16216199>
llvm-svn: 211658
Diffstat (limited to 'lldb/source/Target/Target.cpp')
| -rw-r--r-- | lldb/source/Target/Target.cpp | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/lldb/source/Target/Target.cpp b/lldb/source/Target/Target.cpp index 35b41121c12..9deafa9c6f1 100644 --- a/lldb/source/Target/Target.cpp +++ b/lldb/source/Target/Target.cpp @@ -2642,6 +2642,7 @@ g_properties[] = { "input-path" , OptionValue::eTypeFileSpec , false, 0 , NULL, NULL, "The file/path to be used by the executable program for reading its standard input." }, { "output-path" , OptionValue::eTypeFileSpec , false, 0 , NULL, NULL, "The file/path to be used by the executable program for writing its standard output." }, { "error-path" , OptionValue::eTypeFileSpec , false, 0 , NULL, NULL, "The file/path to be used by the executable program for writing its standard error." }, + { "detach-on-error" , OptionValue::eTypeBoolean , false, true , NULL, NULL, "debugserver will detach (rather than killing) a process if it loses connection with lldb." }, { "disable-aslr" , OptionValue::eTypeBoolean , false, true , NULL, NULL, "Disable Address Space Layout Randomization (ASLR)" }, { "disable-stdio" , OptionValue::eTypeBoolean , false, false , NULL, NULL, "Disable stdin/stdout for process (e.g. for a GUI application)" }, { "inline-breakpoint-strategy" , OptionValue::eTypeEnum , false, eInlineBreakpointsHeaders , NULL, g_inline_breakpoint_enums, "The strategy to use when settings breakpoints by file and line. " @@ -2688,6 +2689,7 @@ enum ePropertyInputPath, ePropertyOutputPath, ePropertyErrorPath, + ePropertyDetachOnError, ePropertyDisableASLR, ePropertyDisableSTDIO, ePropertyInlineStrategy, @@ -2871,6 +2873,20 @@ TargetProperties::SetDisableASLR (bool b) } bool +TargetProperties::GetDetachOnError () const +{ + const uint32_t idx = ePropertyDetachOnError; + return m_collection_sp->GetPropertyAtIndexAsBoolean (NULL, idx, g_properties[idx].default_uint_value != 0); +} + +void +TargetProperties::SetDetachOnError (bool b) +{ + const uint32_t idx = ePropertyDetachOnError; + m_collection_sp->SetPropertyAtIndexAsBoolean (NULL, idx, b); +} + +bool TargetProperties::GetDisableSTDIO () const { const uint32_t idx = ePropertyDisableSTDIO; |

