Author: dperchik Date: Sat Oct 1 05:37:56 2016 New Revision: 283031 URL: http://llvm.org/viewvc/llvm-project?rev=283031&view=rev Log: [lldb-mi] Fix prompt which can get inserted in the middle of program output in lldb-mi
Summary: The code added in svn r264332 causes "(lldb) " to be printed in the middle of program console output. This fix restores the behavior for non-Windows platforms to before the patch. Reviewers: ted, zturner, clayborg Subscribers: amccarth, lldb-commits Differential Revision: http://reviews.llvm.org/D25137 Modified: lldb/trunk/source/Core/IOHandler.cpp Modified: lldb/trunk/source/Core/IOHandler.cpp URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/source/Core/IOHandler.cpp?rev=283031&r1=283030&r2=283031&view=diff ============================================================================== --- lldb/trunk/source/Core/IOHandler.cpp (original) +++ lldb/trunk/source/Core/IOHandler.cpp Sat Oct 1 05:37:56 2016 @@ -590,8 +590,8 @@ void IOHandlerEditline::PrintAsync(Strea else #endif { - const char *prompt = GetPrompt(); #ifdef _MSC_VER + const char *prompt = GetPrompt(); if (prompt) { // Back up over previous prompt using Windows API CONSOLE_SCREEN_BUFFER_INFO screen_buffer_info; @@ -605,9 +605,11 @@ void IOHandlerEditline::PrintAsync(Strea } #endif IOHandler::PrintAsync(stream, s, len); +#ifdef _MSC_VER if (prompt) IOHandler::PrintAsync(GetOutputStreamFile().get(), prompt, strlen(prompt)); +#endif } } _______________________________________________ lldb-commits mailing list lldb-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits