From 523ee1ebf0bf77e7face7856086afe371cc35280 Mon Sep 17 00:00:00 2001 From: tholo Date: Thu, 5 Sep 1996 05:09:10 +0000 Subject: [PATCH] Move fflush() from signal handler into endwin(), that way it will work in some other common situations too. --- lib/libcurses/lib_endwin.c | 2 ++ lib/libcurses/lib_tstp.c | 1 - 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/lib/libcurses/lib_endwin.c b/lib/libcurses/lib_endwin.c index 065b5c7567b..bda6e1949b8 100644 --- a/lib/libcurses/lib_endwin.c +++ b/lib/libcurses/lib_endwin.c @@ -51,5 +51,7 @@ endwin(void) if (curscr && (curscr->_attrs != A_NORMAL)) vidattr(curscr->_attrs = A_NORMAL); + fflush(SP->_ofp); + return(reset_shell_mode()); } diff --git a/lib/libcurses/lib_tstp.c b/lib/libcurses/lib_tstp.c index 7adca9e8cfd..73be68af51c 100644 --- a/lib/libcurses/lib_tstp.c +++ b/lib/libcurses/lib_tstp.c @@ -117,7 +117,6 @@ static void tstp(int dummy) * original (pre-curses) modes. */ endwin(); -fflush(stdout); /* Unblock SIGTSTP. */ (void)sigemptyset(&mask); -- 2.20.1