diff options
author | Michał Górny <mgorny@moritz.systems> | 2020-11-20 17:12:22 +0100 |
---|---|---|
committer | Michał Górny <mgorny@moritz.systems> | 2020-11-23 09:48:55 +0100 |
commit | 18e4272a4fe4667a44f4d323140645a83ddfd864 (patch) | |
tree | 24ca8ce3f6b8be27978b8ca89067194eaad9334c /lldb/source/Plugins/Process/gdb-remote/ProcessGDBRemote.cpp | |
parent | 66ace4dc0275c8d7740bc5ff57c20e85e6660371 (diff) | |
download | llvm-18e4272a4fe4667a44f4d323140645a83ddfd864.zip llvm-18e4272a4fe4667a44f4d323140645a83ddfd864.tar.gz llvm-18e4272a4fe4667a44f4d323140645a83ddfd864.tar.bz2 |
[lldb] Prevent 'process connect' from using local-only plugins
Add a 'can_connect' parameter to Process plugin initialization, and use
it to filter plugins to these capable of remote connections. This is
used to prevent 'process connect' from picking up a plugin that can only
be used locally, e.g. the legacy FreeBSD plugin.
Differential Revision: https://reviews.llvm.org/D91810
Diffstat (limited to 'lldb/source/Plugins/Process/gdb-remote/ProcessGDBRemote.cpp')
-rw-r--r-- | lldb/source/Plugins/Process/gdb-remote/ProcessGDBRemote.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/lldb/source/Plugins/Process/gdb-remote/ProcessGDBRemote.cpp b/lldb/source/Plugins/Process/gdb-remote/ProcessGDBRemote.cpp index 0cd97ab..4c00e9a 100644 --- a/lldb/source/Plugins/Process/gdb-remote/ProcessGDBRemote.cpp +++ b/lldb/source/Plugins/Process/gdb-remote/ProcessGDBRemote.cpp @@ -205,7 +205,8 @@ void ProcessGDBRemote::Terminate() { lldb::ProcessSP ProcessGDBRemote::CreateInstance(lldb::TargetSP target_sp, ListenerSP listener_sp, - const FileSpec *crash_file_path) { + const FileSpec *crash_file_path, + bool can_connect) { lldb::ProcessSP process_sp; if (crash_file_path == nullptr) process_sp = std::make_shared<ProcessGDBRemote>(target_sp, listener_sp); |