diff options
author | Ilia K <ki.stfu@gmail.com> | 2015-02-06 18:15:05 +0000 |
---|---|---|
committer | Ilia K <ki.stfu@gmail.com> | 2015-02-06 18:15:05 +0000 |
commit | 6af632f93c0cfc6138160c807f505d3c1dce2b8f (patch) | |
tree | 460182ebcc7668e7fc973e20b7e3b976b1d642b1 /lldb/source/Target/Process.cpp | |
parent | 56e271568fcccf4f3916c6465b60ca2b6dac5f63 (diff) | |
download | bcm5719-llvm-6af632f93c0cfc6138160c807f505d3c1dce2b8f.tar.gz bcm5719-llvm-6af632f93c0cfc6138160c807f505d3c1dce2b8f.zip |
Fix a missing "*stopped" notification in LLDB-MI after "process launch -s" in case of remote-macosx
Summary:
This patch fixes *stopped notification for remote target when started with eLaunchFlagStopAtEntry (for example, using "process launch -s").
See explanation below:
```
Target::Launch (ProcessLaunchInfo &launch_info, Stream *stream)
{
...
if (state != eStateConnected && platform_sp && platform_sp->CanDebugProcess ())
{
...
}
else
{
...
if (m_process_sp)
error = m_process_sp->Launch (launch_info);
}
if (error.Success())
{
if (launch_info.GetFlags().Test(eLaunchFlagStopAtEntry) == false)
{
....
}
-- missing event if eLaunchFlagStopAtEntry is set --
m_process_sp->RestoreProcessEvents ();
}
...
return error
```
Also this patch contains tests and you can check how it works.
Reviewers: zturner, clayborg, abidh
Reviewed By: clayborg
Subscribers: clayborg, abidh, zturner, lldb-commits
Differential Revision: http://reviews.llvm.org/D7273
llvm-svn: 228417
Diffstat (limited to 'lldb/source/Target/Process.cpp')
-rw-r--r-- | lldb/source/Target/Process.cpp | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/lldb/source/Target/Process.cpp b/lldb/source/Target/Process.cpp index 50d2b5afcf6..7f032686725 100644 --- a/lldb/source/Target/Process.cpp +++ b/lldb/source/Target/Process.cpp @@ -3121,6 +3121,11 @@ Process::Launch (ProcessLaunchInfo &launch_info) StartPrivateStateThread (); m_stop_info_override_callback = GetTarget().GetArchitecture().GetStopInfoOverrideCallback(); + + // Target was stopped at entry as was intended. Need to notify the listeners + // about it. + if (launch_info.GetFlags().Test(eLaunchFlagStopAtEntry) == true) + HandlePrivateEvent(event_sp); } else if (state == eStateExited) { |