Use m_tempfile instead of mktemp in attach/recvattach
[apps/madmutt.git] / pager.c
diff --git a/pager.c b/pager.c
index 05e2c3e..083c9b0 100644 (file)
--- a/pager.c
+++ b/pager.c
@@ -217,16 +217,13 @@ resolve_color (struct line_t *lineInfo, int n, int cnt, int flags,
 
   /* handle "special" bold & underlined characters */
   if (special || a->attr) {
-#ifdef HAVE_COLOR
     if ((a->attr & ANSI_COLOR)) {
       if (a->pair == -1)
         a->pair = mutt_alloc_color (a->fg, a->bg);
       color = a->pair;
       if (a->attr & ANSI_BOLD)
         color |= A_BOLD;
-    }
-    else
-#endif
+    } else
     if ((special & A_BOLD) || (a->attr & ANSI_BOLD)) {
       if (ColorDefs[MT_COLOR_BOLD] && !search)
         color = ColorDefs[MT_COLOR_BOLD];
@@ -771,10 +768,8 @@ static int grok_ansi (unsigned char *buf, int pos, ansi_attr * a)
   /* Character Attributes */
   if (option (OPTALLOWANSI) && a != NULL && buf[x] == 'm') {
     if (pos == x) {
-#ifdef HAVE_COLOR
       if (a->pair != -1)
         mutt_free_color (a->fg, a->bg);
-#endif
       a->attr = ANSI_OFF;
       a->pair = -1;
     }
@@ -803,10 +798,8 @@ static int grok_ansi (unsigned char *buf, int pos, ansi_attr * a)
         pos += 2;
       }
       else if (buf[pos] == '3' && isdigit (buf[pos + 1])) {
-#ifdef HAVE_COLOR
         if (a->pair != -1)
           mutt_free_color (a->fg, a->bg);
-#endif
         a->pair = -1;
         a->attr |= ANSI_COLOR;
         if (buf[pos + 1] != '9')
@@ -814,10 +807,8 @@ static int grok_ansi (unsigned char *buf, int pos, ansi_attr * a)
         pos += 3;
       }
       else if (buf[pos] == '4' && isdigit (buf[pos + 1])) {
-#ifdef HAVE_COLOR
         if (a->pair != -1)
           mutt_free_color (a->fg, a->bg);
-#endif
         a->pair = -1;
         a->attr |= ANSI_COLOR;
         if (buf[pos + 1] != '9')
@@ -1348,8 +1339,8 @@ mutt_pager (const char *banner, const char *fname, int flags, pager_t * extra)
 {
   static char searchbuf[STRING];
   char buffer[LONG_STRING];
-  char helpstr[SHORT_STRING * 2];
-  char tmphelp[SHORT_STRING * 2];
+  char helpstr[STRING * 2];
+  char tmphelp[STRING * 2];
   int maxLine, lastLine = 0;
   struct line_t *lineInfo;
   struct q_class_t *QuoteList = NULL;