[lldb] Move GetEnvironment function into common code (#122173)
This commit is contained in:
@@ -114,6 +114,10 @@ void LogChannelSystem::Initialize() {
|
||||
void LogChannelSystem::Terminate() { g_system_log.Disable(); }
|
||||
|
||||
#if !defined(__APPLE__) && !defined(_WIN32)
|
||||
extern "C" char **environ;
|
||||
|
||||
Environment Host::GetEnvironment() { return Environment(environ); }
|
||||
|
||||
static thread_result_t
|
||||
MonitorChildProcessThreadFunction(::pid_t pid,
|
||||
Host::MonitorChildProcessCallback callback);
|
||||
|
||||
@@ -33,10 +33,6 @@
|
||||
|
||||
#include "llvm/TargetParser/Host.h"
|
||||
|
||||
extern "C" {
|
||||
extern char **environ;
|
||||
}
|
||||
|
||||
namespace lldb_private {
|
||||
class ProcessLaunchInfo;
|
||||
}
|
||||
@@ -241,8 +237,6 @@ bool Host::GetProcessInfo(lldb::pid_t pid, ProcessInstanceInfo &process_info) {
|
||||
return false;
|
||||
}
|
||||
|
||||
Environment Host::GetEnvironment() { return Environment(environ); }
|
||||
|
||||
Status Host::ShellExpandArguments(ProcessLaunchInfo &launch_info) {
|
||||
return Status::FromErrorString("unimplemented");
|
||||
}
|
||||
|
||||
@@ -411,8 +411,6 @@ bool Host::GetProcessInfo(lldb::pid_t pid, ProcessInstanceInfo &process_info) {
|
||||
return GetProcessAndStatInfo(pid, process_info, State, tracerpid);
|
||||
}
|
||||
|
||||
Environment Host::GetEnvironment() { return Environment(environ); }
|
||||
|
||||
Status Host::ShellExpandArguments(ProcessLaunchInfo &launch_info) {
|
||||
return Status::FromErrorString("unimplemented");
|
||||
}
|
||||
|
||||
@@ -35,10 +35,6 @@
|
||||
#include "llvm/Object/ELF.h"
|
||||
#include "llvm/TargetParser/Host.h"
|
||||
|
||||
extern "C" {
|
||||
extern char **environ;
|
||||
}
|
||||
|
||||
using namespace lldb;
|
||||
using namespace lldb_private;
|
||||
|
||||
@@ -46,8 +42,6 @@ namespace lldb_private {
|
||||
class ProcessLaunchInfo;
|
||||
}
|
||||
|
||||
Environment Host::GetEnvironment() { return Environment(environ); }
|
||||
|
||||
static bool GetNetBSDProcessArgs(const ProcessInstanceInfoMatch *match_info_ptr,
|
||||
ProcessInstanceInfo &process_info) {
|
||||
if (!process_info.ProcessIDIsValid())
|
||||
|
||||
@@ -30,10 +30,6 @@
|
||||
|
||||
#include "llvm/TargetParser/Host.h"
|
||||
|
||||
extern "C" {
|
||||
extern char **environ;
|
||||
}
|
||||
|
||||
using namespace lldb;
|
||||
using namespace lldb_private;
|
||||
|
||||
@@ -41,8 +37,6 @@ namespace lldb_private {
|
||||
class ProcessLaunchInfo;
|
||||
}
|
||||
|
||||
Environment Host::GetEnvironment() { return Environment(environ); }
|
||||
|
||||
static bool
|
||||
GetOpenBSDProcessArgs(const ProcessInstanceInfoMatch *match_info_ptr,
|
||||
ProcessInstanceInfo &process_info) {
|
||||
|
||||
Reference in New Issue
Block a user