]> rtime.felk.cvut.cz Git - git.git/blobdiff - imap-send.c
Update draft release notes to 1.7.2
[git.git] / imap-send.c
index 7107923a39247b5c18ad443dc2309971e44abdb4..9d0097ca02960460ff3a104f1739982fee453987 100644 (file)
@@ -1431,8 +1431,14 @@ static int count_messages(struct msg_data *msg)
 
        while (1) {
                if (!prefixcmp(p, "From ")) {
+                       p = strstr(p+5, "\nFrom: ");
+                       if (!p) break;
+                       p = strstr(p+7, "\nDate: ");
+                       if (!p) break;
+                       p = strstr(p+7, "\nSubject: ");
+                       if (!p) break;
+                       p += 10;
                        count++;
-                       p += 5;
                }
                p = strstr(p+5, "\nFrom ");
                if (!p)