X-Git-Url: http://git.madism.org/?a=blobdiff_plain;f=lib-sys%2Fmutt_signal.c;h=8be8fcee3648d177b077e027aae733c5a2502822;hb=df46bef7e086274216fb9072286626ae14ef2617;hp=115460d8cde13f57406bc1cb0fd3f871442826bb;hpb=366c938a78d928880c77bfe31a8715184c918d41;p=apps%2Fmadmutt.git diff --git a/lib-sys/mutt_signal.c b/lib-sys/mutt_signal.c index 115460d..8be8fce 100644 --- a/lib-sys/mutt_signal.c +++ b/lib-sys/mutt_signal.c @@ -49,20 +49,13 @@ static void sighandler (int sig) case SIGCONT: if (!IsEndwin) - refresh (); + wrefresh (stdscr); mutt_curs_set (-1); -#if defined (USE_SLANG_CURSES) || defined (HAVE_RESIZETERM) /* We don't receive SIGWINCH when suspended; however, no harm is done by * just assuming we received one, and triggering the 'resize' anyway. */ - SigWinch = 1; -#endif - break; - -#if defined (USE_SLANG_CURSES) || defined (HAVE_RESIZETERM) case SIGWINCH: SigWinch = 1; break; -#endif case SIGINT: SigInt = 1; @@ -72,13 +65,6 @@ static void sighandler (int sig) errno = save_errno; } -#ifdef USE_SLANG_CURSES -int mutt_intr_hook (void) -{ - return (-1); -} -#endif /* USE_SLANG_CURSES */ - void mutt_signal_initialize (void) { struct sigaction act; @@ -112,9 +98,7 @@ void mutt_signal_initialize (void) sigaction (SIGCONT, &act, NULL); sigaction (SIGTSTP, &act, NULL); sigaction (SIGINT, &act, NULL); -#if defined (USE_SLANG_CURSES) || defined (HAVE_RESIZETERM) sigaction (SIGWINCH, &act, NULL); -#endif /* POSIX doesn't allow us to ignore SIGCHLD, * so we just install a dummy handler for it @@ -125,17 +109,6 @@ void mutt_signal_initialize (void) /* we don't want to mess with stopped children */ act.sa_flags |= SA_NOCLDSTOP; sigaction (SIGCHLD, &act, NULL); - -#ifdef USE_SLANG_CURSES - /* This bit of code is required because of the implementation of - * SLcurses_wgetch(). If a signal is received (like SIGWINCH) when we - * are in blocking mode, SLsys_getkey() will not return an error unless - * a handler function is defined and it returns -1. This is needed so - * that if the user resizes the screen while at a prompt, it will just - * abort and go back to the main-menu. - */ - SLang_getkey_intr_hook = mutt_intr_hook; -#endif } /* signals which are important to block while doing critical ops */ @@ -147,9 +120,7 @@ void mutt_block_signals (void) sigaddset (&Sigset, SIGHUP); sigaddset (&Sigset, SIGTSTP); sigaddset (&Sigset, SIGINT); -#if defined (USE_SLANG_CURSES) || defined (HAVE_RESIZETERM) sigaddset (&Sigset, SIGWINCH); -#endif sigprocmask (SIG_BLOCK, &Sigset, 0); set_option (OPTSIGNALSBLOCKED); }