Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Incorrectly interpreted mail body #157

Closed
zevv opened this issue Oct 8, 2013 · 4 comments · Fixed by #256
Closed

Incorrectly interpreted mail body #157

zevv opened this issue Oct 8, 2013 · 4 comments · Fixed by #256

Comments

@zevv
Copy link

zevv commented Oct 8, 2013

Properly handling different encodings really is a pain in the butt, here is another issue I ran into. This mail body is not interpreted right by sup.

From: [email protected]
To: [email protected]
Subject: Encoding bug
Content-Type: text/plain; charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable

This is =91 a test: the first line seems to disappear from the mail body but is
still visible in the thread view.

There are two issues with this:

  • The mail shows up in the index view, it shows the subject and the first few characters of the mail body, but the wrapping goes wrong: the last 2 characters of the line fold to the left two columns of the next line in the terminal
  • In the thread view the first line is not displayed, only the second line is
    visible (thus only the text "still visible in the thread view.")

Unfortunately I now have an unhappy customer because I missed the first line
of his mail :)

@gauteh
Copy link
Member

gauteh commented Oct 8, 2013

Yeah.. the eternal struggle goes on, sorry to hear it caused problems for you. The Mail gem (#127) would probably perform better, but we're not there yet. Maybe there is something we can tweak... or at least warn the user about the incorrectly parsed e-mail. Was this HTML? Or does the text you pasted above provide a full example?

@zevv
Copy link
Author

zevv commented Oct 8, 2013

No problem, every crash solved leads to a bit more stable sup, which is a good thing.

The original mail was longer, but the above snippet is the minimal mail I can reproduce the content with. I test by passing the above with some HELO etc to port 25 of my mail server.

@gauteh
Copy link
Member

gauteh commented Oct 8, 2013

Great! minimal working example is the best.

@gauteh
Copy link
Member

gauteh commented Mar 12, 2014

This seems to be related to how sup displays the line, the line is parsed alright by RMail.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants