summaryrefslogtreecommitdiffstats
path: root/lldb/source/Plugins/Process
diff options
context:
space:
mode:
Diffstat (limited to 'lldb/source/Plugins/Process')
-rw-r--r--lldb/source/Plugins/Process/POSIX/ProcessPOSIX.cpp14
-rw-r--r--lldb/source/Plugins/Process/POSIX/ProcessPOSIX.h3
-rw-r--r--lldb/source/Plugins/Process/Utility/InferiorCallPOSIX.cpp31
3 files changed, 24 insertions, 24 deletions
diff --git a/lldb/source/Plugins/Process/POSIX/ProcessPOSIX.cpp b/lldb/source/Plugins/Process/POSIX/ProcessPOSIX.cpp
index a5bd9b510a4..62394623c59 100644
--- a/lldb/source/Plugins/Process/POSIX/ProcessPOSIX.cpp
+++ b/lldb/source/Plugins/Process/POSIX/ProcessPOSIX.cpp
@@ -632,20 +632,6 @@ ProcessPOSIX::DoDeallocateMemory(lldb::addr_t addr)
return error;
}
-addr_t
-ProcessPOSIX::ResolveIndirectFunction(const Address *address, Error &error)
-{
- addr_t function_addr = LLDB_INVALID_ADDRESS;
- if (address == NULL) {
- error.SetErrorStringWithFormat("unable to determine direct function call for NULL address");
- } else if (!InferiorCall(this, address, function_addr)) {
- function_addr = LLDB_INVALID_ADDRESS;
- error.SetErrorStringWithFormat("unable to determine direct function call for indirect function %s",
- address->CalculateSymbolContextSymbol()->GetName().AsCString());
- }
- return function_addr;
-}
-
size_t
ProcessPOSIX::GetSoftwareBreakpointTrapOpcode(BreakpointSite* bp_site)
{
diff --git a/lldb/source/Plugins/Process/POSIX/ProcessPOSIX.h b/lldb/source/Plugins/Process/POSIX/ProcessPOSIX.h
index beacb0186c6..7f705d33fe6 100644
--- a/lldb/source/Plugins/Process/POSIX/ProcessPOSIX.h
+++ b/lldb/source/Plugins/Process/POSIX/ProcessPOSIX.h
@@ -104,9 +104,6 @@ public:
virtual lldb_private::Error
DoDeallocateMemory(lldb::addr_t ptr);
- virtual lldb::addr_t
- ResolveIndirectFunction(const lldb_private::Address *address, lldb_private::Error &error);
-
virtual size_t
GetSoftwareBreakpointTrapOpcode(lldb_private::BreakpointSite* bp_site);
diff --git a/lldb/source/Plugins/Process/Utility/InferiorCallPOSIX.cpp b/lldb/source/Plugins/Process/Utility/InferiorCallPOSIX.cpp
index 6d1b04f7f1a..1d5d19fad25 100644
--- a/lldb/source/Plugins/Process/Utility/InferiorCallPOSIX.cpp
+++ b/lldb/source/Plugins/Process/Utility/InferiorCallPOSIX.cpp
@@ -34,9 +34,16 @@
using namespace lldb;
using namespace lldb_private;
-bool lldb_private::InferiorCallMmap(Process *process, addr_t &allocated_addr,
- addr_t addr, addr_t length, unsigned prot,
- unsigned flags, addr_t fd, addr_t offset) {
+bool
+lldb_private::InferiorCallMmap (Process *process,
+ addr_t &allocated_addr,
+ addr_t addr,
+ addr_t length,
+ unsigned prot,
+ unsigned flags,
+ addr_t fd,
+ addr_t offset)
+{
Thread *thread = process->GetThreadList().GetSelectedThread().get();
if (thread == NULL)
return false;
@@ -139,8 +146,11 @@ bool lldb_private::InferiorCallMmap(Process *process, addr_t &allocated_addr,
return false;
}
-bool lldb_private::InferiorCallMunmap(Process *process, addr_t addr,
- addr_t length) {
+bool
+lldb_private::InferiorCallMunmap (Process *process,
+ addr_t addr,
+ addr_t length)
+{
Thread *thread = process->GetThreadList().GetSelectedThread().get();
if (thread == NULL)
return false;
@@ -209,7 +219,14 @@ bool lldb_private::InferiorCallMunmap(Process *process, addr_t addr,
return false;
}
-bool lldb_private::InferiorCall(Process *process, const Address *address, addr_t &returned_func) {
+// FIXME: This has nothing to do with Posix, it is just a convenience function that calls a
+// function of the form "void * (*)(void)". We should find a better place to put this.
+
+bool
+lldb_private::InferiorCall (Process *process,
+ const Address *address,
+ addr_t &returned_func)
+{
Thread *thread = process->GetThreadList().GetSelectedThread().get();
if (thread == NULL || address == NULL)
return false;
@@ -233,7 +250,7 @@ bool lldb_private::InferiorCall(Process *process, const Address *address, addr_t
lldb::ThreadPlanSP call_plan_sp (call_function_thread_plan);
if (call_plan_sp)
{
- StreamFile error_strm;
+ StreamString error_strm;
// This plan is a utility plan, so set it to discard itself when done.
call_plan_sp->SetIsMasterPlan (true);
call_plan_sp->SetOkayToDiscard(true);
OpenPOWER on IntegriCloud