summaryrefslogtreecommitdiffstats
path: root/lldb/source/Interpreter/ScriptInterpreterPython.cpp
diff options
context:
space:
mode:
authorCaroline Tice <ctice@apple.com>2010-10-27 18:34:42 +0000
committerCaroline Tice <ctice@apple.com>2010-10-27 18:34:42 +0000
commit04a339a08493049a3e532bd1271fd8c97d0b095f (patch)
treecf73a88785ff50ab42b504544c9b3c80ecadbada /lldb/source/Interpreter/ScriptInterpreterPython.cpp
parentfbdeab911ac6a98205a260f093c4679beb0c63a2 (diff)
downloadbcm5719-llvm-04a339a08493049a3e532bd1271fd8c97d0b095f.tar.gz
bcm5719-llvm-04a339a08493049a3e532bd1271fd8c97d0b095f.zip
Flush the prompts immediately in the breakpoint command input readers, to make
sure they come out at the correct times. llvm-svn: 117470
Diffstat (limited to 'lldb/source/Interpreter/ScriptInterpreterPython.cpp')
-rw-r--r--lldb/source/Interpreter/ScriptInterpreterPython.cpp7
1 files changed, 7 insertions, 0 deletions
diff --git a/lldb/source/Interpreter/ScriptInterpreterPython.cpp b/lldb/source/Interpreter/ScriptInterpreterPython.cpp
index 7bb94ca72d4..906cb742350 100644
--- a/lldb/source/Interpreter/ScriptInterpreterPython.cpp
+++ b/lldb/source/Interpreter/ScriptInterpreterPython.cpp
@@ -638,6 +638,7 @@ ScriptInterpreterPython::GenerateBreakpointOptionsCommandCallback
::fprintf (out_fh, "%s\n", g_reader_instructions);
if (reader.GetPrompt())
::fprintf (out_fh, "%s", reader.GetPrompt());
+ ::fflush (out_fh);
}
}
break;
@@ -647,7 +648,10 @@ ScriptInterpreterPython::GenerateBreakpointOptionsCommandCallback
case eInputReaderReactivate:
if (reader.GetPrompt() && out_fh)
+ {
::fprintf (out_fh, "%s", reader.GetPrompt());
+ ::fflush (out_fh);
+ }
break;
case eInputReaderGotToken:
@@ -655,7 +659,10 @@ ScriptInterpreterPython::GenerateBreakpointOptionsCommandCallback
std::string temp_string (bytes, bytes_len);
commands_in_progress.AppendString (temp_string.c_str());
if (out_fh && !reader.IsDone() && reader.GetPrompt())
+ {
::fprintf (out_fh, "%s", reader.GetPrompt());
+ ::fflush (out_fh);
+ }
}
break;
OpenPOWER on IntegriCloud