Sicos1977 / MSGReader

C# Outlook MSG file reader without the need for Outlook
http://sicos1977.github.io/MSGReader
MIT License
490 stars 168 forks source link

Bug in RTF Parser results in truncated HTML output. #250

Closed cfhirsch closed 3 years ago

cfhirsch commented 3 years ago

Describe the bug We encountered a bug when we tried to parse a MSG file in RTF format to HTML with the Nuget. Output gets truncated, and it looks like it's due to an issue with the RTF parser.

To Reproduce Steps to reproduce the behavior: I've sent a sample email to the package author.

Expected behavior We would expect the entire contents of the message to be parsed to HTML, but only the first message footer survives the translation to HTML.

Sicos1977 commented 3 years ago

I'll try to look into it this weekend.

Sicos1977 commented 3 years ago

Hi,

I checked your message but it only has an RTF body. To convert RTF to HTML I use RTFPipe (https://github.com/erdomke/RtfPipe)

image

The problem with the translation is somewhere in RTFPipe so it is better to raise an issue overthere.

Greetings, Kees van Spelde

Sicos1977 commented 3 years ago

When I open the rtf body in an RTF reader then this fails so I guess there is some error in the RTF body that Outlook fixes for you.

image

Sicos1977 commented 3 years ago

It goes wrong in RTFPipe somewhere over here

image

But that is as far as I go, it will take forever for me to figure out how RTFPipe works

cfhirsch commented 3 years ago

OK, I'll see if I can engage the authors of RTFPipe. thanks!

erdomke commented 3 years ago

This should be resolved in version 2.0.7677.4303 of RtfPipe.

Sicos1977 commented 3 years ago

I just released a new MSGReader nuget package that has the latest RTFPipe version that fixes your problem.

https://www.nuget.org/packages/MSGReader/3.11.0

Sicos1977 commented 3 years ago

Also thanks to @erdomke for signing the nuget package, this way I don't have to make a signed version myself anymore 👍