remove FILE* usage from ReportEventState() and HandleProcessEvent()
Summary:
This patch adds FileSP and SBFile versions of the API methods
ReportEventState and HandleProcessEvent. It points the SWIG
wrappers at these instead of the ones that use FILE* streams.
Reviewers: JDevlieghere, jasonmolenda, labath, jingham
Reviewed By: labath
Subscribers: lldb-commits
Tags: #lldb
Differential Revision: https://reviews.llvm.org/D68546
llvm-svn: 374816
diff --git a/lldb/scripts/interface/SBDebugger.i b/lldb/scripts/interface/SBDebugger.i
index 208b036..695b32b 100644
--- a/lldb/scripts/interface/SBDebugger.i
+++ b/lldb/scripts/interface/SBDebugger.i
@@ -228,8 +228,14 @@
void
HandleProcessEvent (const lldb::SBProcess &process,
const lldb::SBEvent &event,
- FILE *out,
- FILE *err);
+ SBFile out,
+ SBFile err);
+
+ void
+ HandleProcessEvent (const lldb::SBProcess &process,
+ const lldb::SBEvent &event,
+ FileSP BORROWED,
+ FileSP BORROWED);
lldb::SBTarget
CreateTarget (const char *filename,
diff --git a/lldb/scripts/interface/SBProcess.i b/lldb/scripts/interface/SBProcess.i
index cbe67ad..453f98f 100644
--- a/lldb/scripts/interface/SBProcess.i
+++ b/lldb/scripts/interface/SBProcess.i
@@ -97,7 +97,10 @@
GetAsyncProfileData(char *dst, size_t dst_len) const;
void
- ReportEventState (const lldb::SBEvent &event, FILE *out) const;
+ ReportEventState (const lldb::SBEvent &event, SBFile out) const;
+
+ void
+ ReportEventState (const lldb::SBEvent &event, FileSP BORROWED) const;
void
AppendEventStateReport (const lldb::SBEvent &event, lldb::SBCommandReturnObject &result);