Rocco Rutte:
authorpdmef <pdmef@e385b8ad-14ed-0310-8656-cc95a2468c6d>
Sat, 27 Aug 2005 17:11:39 +0000 (17:11 +0000)
committerpdmef <pdmef@e385b8ad-14ed-0310-8656-cc95a2468c6d>
Sat, 27 Aug 2005 17:11:39 +0000 (17:11 +0000)
- ignore $stuff_quoted when preparing f=f replies
- always display (partial) messages even if body handlers fail; e.g. for invalid passphrases we now at least have gpg/pgp output instead of no output and error 'could not copy message'

git-svn-id: svn://svn.berlios.de/mutt-ng/trunk@452 e385b8ad-14ed-0310-8656-cc95a2468c6d

VERSION.svn
commands.c
rfc3676.c

index 4619a8a..8670c73 100644 (file)
@@ -1 +1 @@
-451
+452
index 4271849..b71c77d 100644 (file)
@@ -155,8 +155,16 @@ int mutt_display_message (HEADER * cur)
       mutt_wait_filter (filterpid);
       safe_fclose (&fpfilterout);
     }
       mutt_wait_filter (filterpid);
       safe_fclose (&fpfilterout);
     }
+#if 0
+    /* this is maybe just plain wrong but it makes the pager display
+     * what we have; i.e. for the crypto stuff we only get
+     * 'Could not copy message' for invalid passphrases, no PGP output
+     * not nothing; so just display what we have...
+     * - pdmef
+     */
     mutt_unlink (tempfile);
     return 0;
     mutt_unlink (tempfile);
     return 0;
+#endif
   }
 
   if (fpfilterout != NULL && mutt_wait_filter (filterpid) != 0)
   }
 
   if (fpfilterout != NULL && mutt_wait_filter (filterpid) != 0)
index 7ca8726..b76108d 100644 (file)
--- a/rfc3676.c
+++ b/rfc3676.c
@@ -52,7 +52,7 @@ static void print_flowed_line (char *line, STATE * s,
 
   if (MaxLineLength > 0) {
     width = MaxLineLength - WrapMargin - ql - 1;
 
   if (MaxLineLength > 0) {
     width = MaxLineLength - WrapMargin - ql - 1;
-    if (option (OPTSTUFFQUOTED))
+    if (!(s->flags & M_REPLYING) && option (OPTSTUFFQUOTED))
       --width;
     if (width < 0)
       width = MaxLineLength;
       --width;
     if (width < 0)
       width = MaxLineLength;
@@ -63,7 +63,7 @@ static void print_flowed_line (char *line, STATE * s,
     else
       width = COLS - WrapMargin - ql - 1;
 
     else
       width = COLS - WrapMargin - ql - 1;
 
-    if (option (OPTSTUFFQUOTED))
+    if (!(s->flags & M_REPLYING) && option (OPTSTUFFQUOTED))
       --width;
     if (width < 0)
       width = COLS;
       --width;
     if (width < 0)
       width = COLS;
@@ -74,7 +74,7 @@ static void print_flowed_line (char *line, STATE * s,
       if (s->prefix)
         state_puts(s->prefix,s);
       for (i=0;i<ql;++i) state_putc('>',s);
       if (s->prefix)
         state_puts(s->prefix,s);
       for (i=0;i<ql;++i) state_putc('>',s);
-      if (option(OPTSTUFFQUOTED))
+      if (!(s->flags & M_REPLYING) && option(OPTSTUFFQUOTED))
         state_putc(' ',s);
     }
     state_putc('\n',s);
         state_putc(' ',s);
     }
     state_putc('\n',s);
@@ -123,7 +123,8 @@ static void print_flowed_line (char *line, STATE * s,
 
     for (i = 0; i < ql; ++i)
       state_putc ('>', s);
 
     for (i = 0; i < ql; ++i)
       state_putc ('>', s);
-    if (option (OPTSTUFFQUOTED) && (ql > 0 || s->prefix))
+    if (!(s->flags & M_REPLYING) && option (OPTSTUFFQUOTED) &&
+        (ql > 0 || s->prefix))
       state_putc (' ', s);
 
     if (delsp && spaces && space_len > 0) {
       state_putc (' ', s);
 
     if (delsp && spaces && space_len > 0) {
@@ -270,9 +271,7 @@ void rfc3676_quote_line (STATE* s, char* dst, size_t dstlen,
   }
   debug_print (4, ("f=f: quotelevel = %d, new prefix = '%s'\n",
                    i, NONULL (quote)));
   }
   debug_print (4, ("f=f: quotelevel = %d, new prefix = '%s'\n",
                    i, NONULL (quote)));
-  /* if we changed prefix, make sure we respect $stuff_quoted */
-  snprintf (dst, dstlen, "%s%s%s%s", NONULL (s->prefix), NONULL (quote),
-            option (OPTSTUFFQUOTED) && line[offset] != ' ' ? " " : "",
+  snprintf (dst, dstlen, "%s%s%s", NONULL (s->prefix), NONULL (quote),
             &line[offset]);
 }
 
             &line[offset]);
 }