diff options
| author | Greg Clayton <gclayton@apple.com> | 2014-07-30 17:38:47 +0000 |
|---|---|---|
| committer | Greg Clayton <gclayton@apple.com> | 2014-07-30 17:38:47 +0000 |
| commit | 06357c930cc13f084e20fe1950a2c849aad22e39 (patch) | |
| tree | 8abf5867fdcbc3795ec772495161d49d769726bd /lldb/source/Interpreter | |
| parent | a12e023c8af35d5f9029d7484e180521e50f4a1f (diff) | |
| download | bcm5719-llvm-06357c930cc13f084e20fe1950a2c849aad22e39.tar.gz bcm5719-llvm-06357c930cc13f084e20fe1950a2c849aad22e39.zip | |
(no commit message)
llvm-svn: 214319
Diffstat (limited to 'lldb/source/Interpreter')
| -rw-r--r-- | lldb/source/Interpreter/CommandInterpreter.cpp | 13 |
1 files changed, 12 insertions, 1 deletions
diff --git a/lldb/source/Interpreter/CommandInterpreter.cpp b/lldb/source/Interpreter/CommandInterpreter.cpp index 33a0912307d..d47b708f18d 100644 --- a/lldb/source/Interpreter/CommandInterpreter.cpp +++ b/lldb/source/Interpreter/CommandInterpreter.cpp @@ -3141,7 +3141,16 @@ CommandInterpreter::RunCommandInterpreter(bool auto_handle_events, bool spawn_thread) { const bool multiple_lines = false; // Only get one line at a time - if (!m_command_io_handler_sp) + if (m_command_io_handler_sp) + { + // Copy the current debugger file handles in case they changed. + m_command_io_handler_sp->GetInputStreamFile() = m_debugger.GetInputFile(); + m_command_io_handler_sp->GetOutputStreamFile() = m_debugger.GetOutputFile(); + m_command_io_handler_sp->GetErrorStreamFile() = m_debugger.GetErrorFile(); + m_command_io_handler_sp->SetIsDone(false); + } + else + { m_command_io_handler_sp.reset(new IOHandlerEditline (m_debugger, m_debugger.GetInputFile(), m_debugger.GetOutputFile(), @@ -3152,6 +3161,8 @@ CommandInterpreter::RunCommandInterpreter(bool auto_handle_events, multiple_lines, 0, // Don't show line numbers *this)); + } + m_debugger.PushIOHandler(m_command_io_handler_sp); if (auto_handle_events) |

