Recently started happening (I'm using version 3.17.3git156).
When forwarding a mail, it sometimes fails with:
** error occurred on SMTP session
*** Error occurred while sending the message:
550 maximum allowed line length is 998 octets, got 1650
Only started happening in the last month or so.
(In reply to comment #0)
> Recently started happening (I'm using version 3.17.3git156).
Current git version is 3.17.3git128.
That's what the 'About' box says (see attached).
Last git log:
Author: Michael Rasmussen <firstname.lastname@example.org>
Date: Sat Mar 2 13:25:13 2019 +0100
Remove useless debug code. Add copyright
Signed-off-by: Michael Rasmussen <email@example.com>
Created attachment 1964 [details]
On a clean git pull that would be 3.17.3git113. (3.17.3-113-g9b0f657)
Looks like the 'About' box has a bug too, then.
(In reply to comment #5)
> Looks like the 'About' box has a bug too, then.
No, not at all.
I'm not getting into a pissing contest over this: call it whatever version you want, but please don't question the git version in a bug report when it was copypasta from the About box.
(In reply to comment #7)
> I'm not getting into a pissing contest over this: call it whatever version
> you want, but please don't question the git version in a bug report when it
> was copypasta from the About box.
You are the only one in the pissing contest, so you win.
I asked because there isn't an official 3.17.3git156 yet. And like I say a clean git checkout would not produce that version number, so I wanted you to confirm which version you are using, because git156 tells no-one anything.
However, this is a (known) problem of the way claws-mail handles versioning via git. It is not a criticism of you in any way, so no need to take it as one.
Claws Mail warns you when attempting to send a message which exceeds the line length limit. A popup dialogue says:
Line %d exceeds the line length limit (998 bytes).
The contents of the message might be broken on the way to the delivery
Send it anyway?
Do you not see this?
What are your settings on the Wrapping page of the preferences?
I do not see that dialog in this context (I'm familiar with it, but it isn't being displayed when this bug occurs).
Wrapping settings: all four boxes ticked, wrap at 75 characters.
I don't believe this is a display/editing bug. I believe it is identifying a contravention of RFC2822 section 2.1.1, "Each line of characters MUST be no more than 998 characters, and SHOULD be no more than 78 characters, excluding the CRLF." The error I'm seeing is from the MUST clause; the wrapping settings and warning you refer to are from the SHOULD clause. I may be wrong, but that's my interpretaion.
I have forwarded mails using Claws for years. It is only in the past 4-6 weeks (using builds from git) that this problem has occurred.
Created attachment 1965 [details]
Mail that fails when forwarded
The attached mail fails as per this bug when forwarded. Git version of claws is commit cd9afd9b09881c116c7b932c2bd4643c96d0729f
Thanks for the example mail.
It forwards fine here. I tried with 2 different servers.
That may be because your SMTP server doesn't reject mail with lines>998 bytes.
What I have done is compare the original mail with the one "stuck" in the Queue folder after forwarding. The original mail is (horrible) HTML,but this is an extract from it, and is three lines long:
<p class=3D"MsoNormal">Just thought I would drop you an email, I am now wor=
king with companies in your area doing regular confidential shr=
The same section from the queued mail is one line long:
<p class="MsoNormal">Just thought I would drop you an email, I am now working with companies in your area doing regular confidential shredding.<o:p></o:p></p>
That particular line doesn't exceed the 998 byte count, but it's easy to see how it could.
To save the mails, I'm right-clicking on the message/rfc822 part and saving. I'm comparing the pre- and post-forwarded versions with meld (under Linux), which makes it a little easier to see than my preferred vimdiff.
You might want to compare the mail that is received after forwarding with the un-forwarded original.
When forwarding a messages with line length exceeding 998 you will see that warning dialogue detailed in comment #9.
The example message that you attached does not exceed 998 bytes on any line, it is well wrapped.
This all suggests to me that you should enqure with the SMTP server operator regarding this problem.
> When forwarding a messages with line length exceeding 998 you will see
> that warning dialogue detailed in comment #9.
Agreed, but - as you state below - the message doesn't have any lines in it that exceed 998 bytes.
> The example message that you attached does not exceed 998 bytes on any
> line, it is well wrapped.
Agreed. That what I said in Comment #13.
> This all suggests to me that you should enqure with the SMTP server
> operator regarding this problem.
You're ignoring the fact that, as described in Comment #13, claws appears to be changing this particular message when forwarding such that the line length does exceed 998 bytes.
Step by step instructions to demonstrate the problem. Starting point: the attached mail is present in your inbox.
1. Select mail
2. Menu: Message, forward
3. Insert an address it the To: box
4. Menu: Message, Send later
5. Select the message in the Queue folder
6. Menu: File, Save email as...
7. In a shell window:
$ wc -L themessage.eml
(Note: the -L switch to wc only works on Linux, not MacOS. It displays the length of the longest line in the file argument).
(In reply to comment #15)
> You're ignoring the fact that, as described in Comment #13, claws appears to
> be changing this particular message when forwarding such that the line
> length does exceed 998 bytes.
Not ignoring, just somehow overlooked it completely.
But, yes, I can confirm what you said.
Created attachment 1971 [details]
Try this patch.
Changes related to this bug have been committed.
Please check latest Git and update the bug accordingly.
You can also get the patch from:
++ ChangeLog 2019-04-21 12:45:03.969267969 +0200
Author: Paul <firstname.lastname@example.org>
Date: Sun Apr 21 11:44:00 2019 +0100
fix bug 4167, 'Max line length exceeded when forwarding mail'