summaryrefslogtreecommitdiffstats
path: root/lldb/source/API/SBDebugger.cpp
diff options
context:
space:
mode:
authorJason Molenda <jmolenda@apple.com>2017-11-02 02:43:27 +0000
committerJason Molenda <jmolenda@apple.com>2017-11-02 02:43:27 +0000
commitedc2def4a65764991ffb50e9c9af1c740ced534c (patch)
tree1956183f5d71079fc4d2e3503a5e892c8d27dbda /lldb/source/API/SBDebugger.cpp
parent9e27b70a07c35880da49619bd85ce47cb327fb02 (diff)
downloadbcm5719-llvm-edc2def4a65764991ffb50e9c9af1c740ced534c.tar.gz
bcm5719-llvm-edc2def4a65764991ffb50e9c9af1c740ced534c.zip
Commit Lawrence D'Anna's patch to change
SetOututFileHandle to work with IOBase. I did make one change after checking with Larry -- I renamed SBDebugger::Flush to FlushDebuggerOutputHandles and added a short docstring to the .i file to make it a little clearer under which context programs may need to use this API. Differential Revision: https://reviews.llvm.org/D39128 <rdar://problem/34870417> llvm-svn: 317182
Diffstat (limited to 'lldb/source/API/SBDebugger.cpp')
-rw-r--r--lldb/source/API/SBDebugger.cpp12
1 files changed, 12 insertions, 0 deletions
diff --git a/lldb/source/API/SBDebugger.cpp b/lldb/source/API/SBDebugger.cpp
index d3294dab582..af883acf1ad 100644
--- a/lldb/source/API/SBDebugger.cpp
+++ b/lldb/source/API/SBDebugger.cpp
@@ -270,6 +270,18 @@ void SBDebugger::SetInputFileHandle(FILE *fh, bool transfer_ownership) {
m_opaque_sp->SetInputFileHandle(fh, transfer_ownership);
}
+void SBDebugger::FlushDebuggerOutputHandles() {
+ Log *log(GetLogIfAllCategoriesSet(LIBLLDB_LOG_API));
+
+ if (log)
+ log->Printf(
+ "SBDebugger(%p)::FlushDebuggerOutputHandles ()",
+ static_cast<void *>(m_opaque_sp.get()));
+
+ if (m_opaque_sp)
+ m_opaque_sp->FlushDebuggerOutputHandles();
+}
+
void SBDebugger::SetOutputFileHandle(FILE *fh, bool transfer_ownership) {
Log *log(GetLogIfAllCategoriesSet(LIBLLDB_LOG_API));
OpenPOWER on IntegriCloud