]> granicus.if.org Git - mutt/commitdiff
Some fixes to the macro-function patch.
authorThomas Roessler <roessler@does-not-exist.org>
Mon, 5 Oct 1998 18:42:56 +0000 (18:42 +0000)
committerThomas Roessler <roessler@does-not-exist.org>
Mon, 5 Oct 1998 18:42:56 +0000 (18:42 +0000)
compose.c
flags.c

index 40bb49276c5bde1ac80de8c63f3481e1d0838e6f..263bedc5befa1c75ca64c0f7ce92d5c304d9ec61 100644 (file)
--- a/compose.c
+++ b/compose.c
@@ -85,7 +85,7 @@ void snd_entry (char *b, size_t blen, MUTTMENU *menu, int num)
 
 static int pgp_send_menu (int bits)
 {
-  int c;
+  event_t ch;
   char *p;
   char *micalg = NULL;
   char input_signas[SHORT_STRING];
@@ -99,9 +99,12 @@ static int pgp_send_menu (int bits)
   do
   {
     mutt_refresh ();
-    if ((c = mutt_getch ()) == ERR)
+    
+    ch  = mutt_getch();
+    if (ch.ch == EOF)
       break;
-    if (c == 'a')
+
+    if (ch.ch == 'a')
     {
       unset_option(OPTPGPCHECKTRUST);
       
@@ -136,7 +139,7 @@ static int pgp_send_menu (int bits)
        mutt_error _("An unkown PGP version was defined for signing.");
       }
     }
-    else if (c == 'm')
+    else if (ch.ch == 'm')
     {
       if(!(bits & PGPSIGN))
        mutt_error _("This doesn't make sense if you don't want to sign the message.");
@@ -160,21 +163,21 @@ static int pgp_send_menu (int bits)
        }
       }
     }
-    else if (c == 'e')
+    else if (ch.ch == 'e')
       bits |= PGPENCRYPT;
-    else if (c == 's')
+    else if (ch.ch == 's')
       bits |= PGPSIGN;
-    else if (c == 'b')
+    else if (ch.ch == 'b')
       bits = PGPENCRYPT | PGPSIGN;
-    else if (c == 'f')
+    else if (ch.ch == 'f')
       bits = 0;
     else
     {
       BEEP ();
-      c = 0;
+      ch.ch = 0;
     }
   }
-  while (c == 0);
+  while (ch.ch == 0);
   CLEARLINE (LINES-1);
   mutt_refresh ();
   return (bits);
diff --git a/flags.c b/flags.c
index b53f2c18013bcb59cfc5f4c867bdb8ef097b2db9..3ea6c44a9d1920913309726bf3203024b1c30d65 100644 (file)
--- a/flags.c
+++ b/flags.c
@@ -252,7 +252,7 @@ int mutt_change_flag (HEADER *h, int bf)
   int i, flag;
   event_t event;
 
-  mvprintw (LINES - 1, 0, "%s flag? (D/N/O/r/*/!): ", bf ? _("Set") : _("Clear"));
+  mvprintw (LINES - 1, 0, "%s? (D/N/O/r/*/!): ", bf ? _("Set flag") : _("Clear flag"));
   clrtoeol ();
 
   event = mutt_getch();