summaryrefslogtreecommitdiffhomepage
path: root/src/console
diff options
context:
space:
mode:
Diffstat (limited to 'src/console')
-rw-r--r--src/console/ptyc_console_writer.c17
1 files changed, 10 insertions, 7 deletions
diff --git a/src/console/ptyc_console_writer.c b/src/console/ptyc_console_writer.c
index 1729ea9..24509f8 100644
--- a/src/console/ptyc_console_writer.c
+++ b/src/console/ptyc_console_writer.c
@@ -159,13 +159,16 @@ static void * __fastcall ptyc_flush_screen_buffer(struct ptyc_term_ctx * tctx)
&nwritten,
0);
- ntcon->get_console_screen_buffer_info(
- tctx->hout,
- &tctx->screen_info);
-
- ntcon->set_console_cursor_position(
- tctx->hout,
- tctx->screen_info.cursor_position);
+ /* heuristics: interactive input? */
+ if (ncunits <= 4) {
+ ntcon->get_console_screen_buffer_info(
+ tctx->hout,
+ &tctx->screen_info);
+
+ ntcon->set_console_cursor_position(
+ tctx->hout,
+ tctx->screen_info.cursor_position);
+ }
tctx->wch_con = tctx->data.screen;