# HG changeset patch # User jwe # Date 853989389 0 # Node ID aa667ac18d12ba37bdf96ec8a5e9ae4d7e35a043 # Parent a27986cc41774c23e8bec3970eb1c32fa7cd4f4e [project @ 1997-01-23 03:16:28 by jwe] diff --git a/src/ChangeLog b/src/ChangeLog --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,12 @@ +Wed Jan 22 20:54:12 1997 John W. Eaton + + * input.cc (gnu_readline): If not using readline, flush + rl_outstream after printing prompt. + (octave_gets): Also call flush_octave_stdout() if + forced_interactive, not just if interactive. + (do_input_echo): If forced_interactive, only echo prompt and + command line if also reading a script file. + Tue Jan 21 23:02:34 1997 John W. Eaton * SLList.h: Include "BaseSLList.h", not . diff --git a/src/input.cc b/src/input.cc --- a/src/input.cc +++ b/src/input.cc @@ -387,7 +387,7 @@ { int do_echo = reading_script_file ? (Vecho_executing_commands & ECHO_SCRIPTS) - : (Vecho_executing_commands & ECHO_CMD_LINE); + : (Vecho_executing_commands & ECHO_CMD_LINE) && ! forced_interactive; if (do_echo) { @@ -430,7 +430,10 @@ else { if (s && *s && (interactive || forced_interactive)) - fprintf (rl_outstream, s); + { + fprintf (rl_outstream, s); + fflush (rl_outstream); + } FILE *curr_stream = rl_instream; if (reading_fcn_file || reading_script_file) @@ -493,11 +496,9 @@ string prompt = decode_prompt_string (ps); - if (interactive) - { - pipe_handler_error_count = 0; - flush_octave_stdout (); - } + pipe_handler_error_count = 0; + + flush_octave_stdout (); octave_diary << prompt;