]> granicus.if.org Git - neomutt/commitdiff
Add ifdefs around new mutt_resize_screen calls.
authorKevin McCarthy <kevin@8t8.us>
Sat, 15 Apr 2017 19:56:42 +0000 (12:56 -0700)
committerRichard Russon <rich@flatcap.org>
Tue, 18 Apr 2017 12:44:29 +0000 (13:44 +0100)
Changeset 231fa2eff206 added sigwinch handling to _mutt_enter_string()
but neglected to add an ifdef check.

curs_lib.c
enter.c

index 05a2cfed59d5898292d709d316ba1307bbc4bc1b..0ac4e7a23e26c92b2ec5764e9d4ebf095745fb8f 100644 (file)
@@ -162,6 +162,7 @@ int _mutt_get_field(const char *field, char *buf, size_t buflen, int complete,
 
   do
   {
+#if defined(USE_SLANG_CURSES) || defined(HAVE_RESIZETERM)
     if (SigWinch)
     {
       SigWinch = 0;
@@ -172,6 +173,7 @@ int _mutt_get_field(const char *field, char *buf, size_t buflen, int complete,
       clearok(stdscr, TRUE);
       mutt_current_menu_redraw();
     }
+#endif
     mutt_window_clearline(MuttMessageWindow, 0);
     SETCOLOR(MT_COLOR_PROMPT);
     addstr((char *) field); /* cast to get around bad prototypes */
diff --git a/enter.c b/enter.c
index a63da70cf6aa7893029038b37eb4ba0e9a046076..fb5acd056ee187dd9421c85f1677ccf1732af770 100644 (file)
--- a/enter.c
+++ b/enter.c
@@ -215,12 +215,14 @@ int mutt_enter_string(char *buf, size_t buflen, int col, int flags)
   ENTER_STATE *es = mutt_new_enter_state();
   do
   {
+#if defined(USE_SLANG_CURSES) || defined(HAVE_RESIZETERM)
     if (SigWinch)
     {
       SigWinch = 0;
       mutt_resize_screen();
       clearok(stdscr, TRUE);
     }
+#endif
     rv = _mutt_enter_string(buf, buflen, col, flags, 0, NULL, NULL, es);
   } while (rv == 1);
   mutt_free_enter_state(&es);