Commit d764632f authored by Yukihiro "Matz" Matsumoto's avatar Yukihiro "Matz" Matsumoto

Merge pull request #2680 from sdottaka/add-fflush

mrdb, mirb: Add fflush() so that a external program can read output imme...
parents 1c48be78 71548aab
......@@ -466,6 +466,7 @@ dbgcmd_quit(mrb_state *mrb, mrdb_state *mrdb)
int buf;
printf("The program is running. Exit anyway? (y or n) ");
fflush(stdout);
if ((buf = getchar()) == EOF) {
mrdb->dbg->xm = DBG_QUIT;
......
......@@ -478,6 +478,7 @@ get_and_parse_command(mrb_state *mrb, mrdb_state *mrdb)
while (!cmd) {
for (p=NULL; !p || *p=='\0'; ) {
printf("(%s:%d) ", mrdb->dbg->prvfile, mrdb->dbg->prvline);
fflush(stdout);
p = get_command(mrb, mrdb);
}
......
......@@ -278,6 +278,7 @@ print_cmdline(int code_block_open)
else {
printf("> ");
}
fflush(stdout);
}
#endif
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment