File tree Expand file tree Collapse file tree 2 files changed +10
-8
lines changed Expand file tree Collapse file tree 2 files changed +10
-8
lines changed Original file line number Diff line number Diff line change @@ -16,7 +16,9 @@ DESCRIPTION
16
16
This command uploads a mailbox generated with 'git format-patch'
17
17
into an IMAP drafts folder. This allows patches to be sent as
18
18
other email is when using mail clients that cannot read mailbox
19
- files directly.
19
+ files directly. The command also works with any general mailbox
20
+ in which emails have the fields "From", "Date", and "Subject" in
21
+ that order.
20
22
21
23
Typical usage is something like:
22
24
@@ -122,12 +124,6 @@ Thunderbird in particular is known to be problematic. Thunderbird
122
124
users may wish to visit this web page for more information:
123
125
http://kb.mozillazine.org/Plain_text_e-mail_-_Thunderbird#Completely_plain_email
124
126
125
-
126
- BUGS
127
- ----
128
- Doesn't handle lines starting with "From " in the message body.
129
-
130
-
131
127
Author
132
128
------
133
129
Derived from isync 1.0.1 by Mike McCormack.
Original file line number Diff line number Diff line change @@ -1431,8 +1431,14 @@ static int count_messages(struct msg_data *msg)
1431
1431
1432
1432
while (1 ) {
1433
1433
if (!prefixcmp (p , "From " )) {
1434
+ p = strstr (p + 5 , "\nFrom: " );
1435
+ if (!p ) break ;
1436
+ p = strstr (p + 7 , "\nDate: " );
1437
+ if (!p ) break ;
1438
+ p = strstr (p + 7 , "\nSubject: " );
1439
+ if (!p ) break ;
1440
+ p += 10 ;
1434
1441
count ++ ;
1435
- p += 5 ;
1436
1442
}
1437
1443
p = strstr (p + 5 , "\nFrom " );
1438
1444
if (!p )
You can’t perform that action at this time.
0 commit comments