]> granicus.if.org Git - neomutt/commitdiff
Fix message parsing. This fixes the "Reply-To in body" bug. From
authorThomas Roessler <roessler@does-not-exist.org>
Sat, 22 Apr 2000 08:49:29 +0000 (08:49 +0000)
committerThomas Roessler <roessler@does-not-exist.org>
Sat, 22 Apr 2000 08:49:29 +0000 (08:49 +0000)
Edmund GRIMLEY EVANS.

parse.c

diff --git a/parse.c b/parse.c
index ccace28b4f63b93984c47e785254db4b2c6e2c3a..011d602870f7fab6c825b7a64a3219ba2f15263e 100644 (file)
--- a/parse.c
+++ b/parse.c
@@ -898,8 +898,8 @@ ENVELOPE *mutt_read_rfc822_header (FILE *f, HEADER *hdr, short user_hdrs,
     }
   }
 
-  loc = ftell (f);
-  while (*(line = read_rfc822_line (f, line, &linelen)) != 0)
+  while ((loc = ftell (f)),
+         *(line = read_rfc822_line (f, line, &linelen)) != 0)
   {
     matched = 0;
 
@@ -910,16 +910,12 @@ ENVELOPE *mutt_read_rfc822_header (FILE *f, HEADER *hdr, short user_hdrs,
 
       /* some bogus MTAs will quote the original "From " line */
       if (mutt_strncmp (">From ", line, 6) == 0)
-      {
-       loc = ftell (f);
        continue; /* just ignore */
-      }
       else if ((t = is_from (line, return_path, sizeof (return_path))))
       {
        /* MH somtimes has the From_ line in the middle of the header! */
        if (hdr && !hdr->received)
          hdr->received = t - mutt_local_tz (t);
-       loc = ftell (f);
        continue;
       }
 
@@ -1210,8 +1206,6 @@ ENVELOPE *mutt_read_rfc822_header (FILE *f, HEADER *hdr, short user_hdrs,
       rfc2047_decode (line, line, linelen);
       last->data = safe_strdup (line);
     }
-
-    loc = ftell (f);
   }
 
   FREE (&line);