summaryrefslogtreecommitdiffstats
path: root/lldb/source/Plugins/Process/Windows
diff options
context:
space:
mode:
authorJim Ingham <jingham@apple.com>2016-03-07 21:50:25 +0000
committerJim Ingham <jingham@apple.com>2016-03-07 21:50:25 +0000
commit583bbb1dd46e1665c2d5f31d4e4772bf6207c1c0 (patch)
tree08371c4b8334ea4e9a7f1ce3d29420712fd7949a /lldb/source/Plugins/Process/Windows
parent2a831fb8264e6a53a8b08b90107f3b176c152db2 (diff)
downloadbcm5719-llvm-583bbb1dd46e1665c2d5f31d4e4772bf6207c1c0.tar.gz
bcm5719-llvm-583bbb1dd46e1665c2d5f31d4e4772bf6207c1c0.zip
Change over the broadcaster/listener process to hold shared or weak pointers
to each other. This should remove some infrequent teardown crashes when the listener is not the debugger's listener. Processes now need to take a ListenerSP, not a Listener&. This required changing over the Process plugin class constructors to take a ListenerSP, instead of a Listener&. Other than that there should be no functional change. <rdar://problem/24580184> CrashTracer: [USER] Xcode at …ework: lldb_private::Listener::BroadcasterWillDestruct + 39 llvm-svn: 262863
Diffstat (limited to 'lldb/source/Plugins/Process/Windows')
-rw-r--r--lldb/source/Plugins/Process/Windows/Common/ProcessWindows.cpp4
-rw-r--r--lldb/source/Plugins/Process/Windows/Common/ProcessWindows.h2
-rw-r--r--lldb/source/Plugins/Process/Windows/Live/ProcessWindowsLive.cpp8
-rw-r--r--lldb/source/Plugins/Process/Windows/Live/ProcessWindowsLive.h4
-rw-r--r--lldb/source/Plugins/Process/Windows/MiniDump/ProcessWinMiniDump.cpp6
-rw-r--r--lldb/source/Plugins/Process/Windows/MiniDump/ProcessWinMiniDump.h4
6 files changed, 14 insertions, 14 deletions
diff --git a/lldb/source/Plugins/Process/Windows/Common/ProcessWindows.cpp b/lldb/source/Plugins/Process/Windows/Common/ProcessWindows.cpp
index 0e6900d8fb7..2c3f9fbecf9 100644
--- a/lldb/source/Plugins/Process/Windows/Common/ProcessWindows.cpp
+++ b/lldb/source/Plugins/Process/Windows/Common/ProcessWindows.cpp
@@ -29,8 +29,8 @@ namespace lldb_private
//------------------------------------------------------------------------------
// Constructors and destructors.
-ProcessWindows::ProcessWindows(lldb::TargetSP target_sp, Listener &listener)
- : lldb_private::Process(target_sp, listener)
+ProcessWindows::ProcessWindows(lldb::TargetSP target_sp, lldb::ListenerSP listener_sp)
+ : lldb_private::Process(target_sp, listener_sp)
{
}
diff --git a/lldb/source/Plugins/Process/Windows/Common/ProcessWindows.h b/lldb/source/Plugins/Process/Windows/Common/ProcessWindows.h
index 2a437c0ca90..0ee42e2ae1f 100644
--- a/lldb/source/Plugins/Process/Windows/Common/ProcessWindows.h
+++ b/lldb/source/Plugins/Process/Windows/Common/ProcessWindows.h
@@ -25,7 +25,7 @@ public:
// Constructors and destructors
//------------------------------------------------------------------
ProcessWindows(lldb::TargetSP target_sp,
- lldb_private::Listener &listener);
+ lldb::ListenerSP listener_sp);
~ProcessWindows();
diff --git a/lldb/source/Plugins/Process/Windows/Live/ProcessWindowsLive.cpp b/lldb/source/Plugins/Process/Windows/Live/ProcessWindowsLive.cpp
index 45ef8366f8f..9516040edc6 100644
--- a/lldb/source/Plugins/Process/Windows/Live/ProcessWindowsLive.cpp
+++ b/lldb/source/Plugins/Process/Windows/Live/ProcessWindowsLive.cpp
@@ -121,9 +121,9 @@ class ProcessWindowsData
// Static functions.
ProcessSP
-ProcessWindowsLive::CreateInstance(lldb::TargetSP target_sp, Listener &listener, const FileSpec *)
+ProcessWindowsLive::CreateInstance(lldb::TargetSP target_sp, lldb::ListenerSP listener_sp, const FileSpec *)
{
- return ProcessSP(new ProcessWindowsLive(target_sp, listener));
+ return ProcessSP(new ProcessWindowsLive(target_sp, listener_sp));
}
void
@@ -142,8 +142,8 @@ ProcessWindowsLive::Initialize()
//------------------------------------------------------------------------------
// Constructors and destructors.
-ProcessWindowsLive::ProcessWindowsLive(lldb::TargetSP target_sp, Listener &listener)
- : lldb_private::ProcessWindows(target_sp, listener)
+ProcessWindowsLive::ProcessWindowsLive(lldb::TargetSP target_sp, lldb::ListenerSP listener_sp)
+ : lldb_private::ProcessWindows(target_sp, listener_sp)
{
}
diff --git a/lldb/source/Plugins/Process/Windows/Live/ProcessWindowsLive.h b/lldb/source/Plugins/Process/Windows/Live/ProcessWindowsLive.h
index 2429f873c82..657877f529b 100644
--- a/lldb/source/Plugins/Process/Windows/Live/ProcessWindowsLive.h
+++ b/lldb/source/Plugins/Process/Windows/Live/ProcessWindowsLive.h
@@ -43,7 +43,7 @@ public:
//------------------------------------------------------------------
static lldb::ProcessSP
CreateInstance(lldb::TargetSP target_sp,
- lldb_private::Listener &listener,
+ lldb::ListenerSP listener_sp,
const lldb_private::FileSpec *);
static void
@@ -62,7 +62,7 @@ public:
// Constructors and destructors
//------------------------------------------------------------------
ProcessWindowsLive(lldb::TargetSP target_sp,
- lldb_private::Listener &listener);
+ lldb::ListenerSP listener_sp);
~ProcessWindowsLive();
diff --git a/lldb/source/Plugins/Process/Windows/MiniDump/ProcessWinMiniDump.cpp b/lldb/source/Plugins/Process/Windows/MiniDump/ProcessWinMiniDump.cpp
index 1343886fa9d..c39f77f441e 100644
--- a/lldb/source/Plugins/Process/Windows/MiniDump/ProcessWinMiniDump.cpp
+++ b/lldb/source/Plugins/Process/Windows/MiniDump/ProcessWinMiniDump.cpp
@@ -538,7 +538,7 @@ ProcessWinMiniDump::Terminate()
}
lldb::ProcessSP
-ProcessWinMiniDump::CreateInstance(lldb::TargetSP target_sp, Listener &listener, const FileSpec *crash_file)
+ProcessWinMiniDump::CreateInstance(lldb::TargetSP target_sp, lldb::ListenerSP listener_sp, const FileSpec *crash_file)
{
lldb::ProcessSP process_sp;
if (crash_file)
@@ -555,8 +555,8 @@ ProcessWinMiniDump::CanDebug(lldb::TargetSP target_sp, bool plugin_specified_by_
return true;
}
-ProcessWinMiniDump::ProcessWinMiniDump(lldb::TargetSP target_sp, Listener &listener, const FileSpec &core_file)
- : ProcessWindows(target_sp, listener), m_impl_up(new Impl(core_file, this))
+ProcessWinMiniDump::ProcessWinMiniDump(lldb::TargetSP target_sp, lldb::ListenerSP listener_sp, const FileSpec &core_file)
+ : ProcessWindows(target_sp, listener_sp), m_impl_up(new Impl(core_file, this))
{
}
diff --git a/lldb/source/Plugins/Process/Windows/MiniDump/ProcessWinMiniDump.h b/lldb/source/Plugins/Process/Windows/MiniDump/ProcessWinMiniDump.h
index 4239115576b..3e1ac4bffbe 100644
--- a/lldb/source/Plugins/Process/Windows/MiniDump/ProcessWinMiniDump.h
+++ b/lldb/source/Plugins/Process/Windows/MiniDump/ProcessWinMiniDump.h
@@ -26,7 +26,7 @@ class ProcessWinMiniDump : public lldb_private::ProcessWindows
public:
static lldb::ProcessSP
CreateInstance (lldb::TargetSP target_sp,
- lldb_private::Listener &listener,
+ lldb::ListenerSP listener_sp,
const lldb_private::FileSpec *crash_file_path);
static void
@@ -42,7 +42,7 @@ class ProcessWinMiniDump : public lldb_private::ProcessWindows
GetPluginDescriptionStatic();
ProcessWinMiniDump(lldb::TargetSP target_sp,
- lldb_private::Listener &listener,
+ lldb::ListenerSP listener_sp,
const lldb_private::FileSpec &core_file);
virtual
OpenPOWER on IntegriCloud