Re: odd email parsing (misparsing?) issue



Hi Jack:

On Nov 14, 2014, at 11:02 AM, Jack wrote:
...
Problem: I found at least one mbox file that seemed to put balsa into a 100% CPU chewing mode, with the status area in the lower left just moving the bar back and forth forever. By manually editing the mbox file, and moving a few messages at a time into a separate file, I finally found what I think is the culprit, although I'm sure I've looked at this message in the past without problems. The body of the message includes a line that starts with "From " immediately after a blank line, and I wonder if balsa is getting confused by thinking this should start a new message, but not finding any header lines following it? Changing this line by adding text at the beginning "This is From..." let balsa deal with it without any further problem.

What SHOULD happen with such a message? Should that line be quoted in some way? Should the lack of a header ("^.*: .*$" with perhaps length limits on what is before and after the ": " ?) be taken to say this is NOT the start of a new message?

Yes, a line beginning "From " is the marker for the beginning of a message in an mbox file. I believe the preceding blank line isn't relevant. If the Content-Transfer-Encoding is quoted-printable, a line like that should be encoded as "=46rom ", precisely to avoid being misinterpreted. Balsa uses that encoding, but apparently such a line occasionally gets through. I've seen it lead to misparsing, but I don't recall seeing the pegged-cpu issue. Either way, hand-editing is probably the best fix!

Peter

Attachment: pgpe7o2f8g54m.pgp
Description: PGP signature



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]