Skip to content

Commit

Permalink
Merge pull request #470 from humayun-ahmed/master
Browse files Browse the repository at this point in the history
The TNEF AttachDisposition value format is of the form "inline; filename=image.jpeg"
  • Loading branch information
jstedfast authored Mar 12, 2019
2 parents 5150b22 + fd6b17b commit b127477
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions MimeKit/Tnef/TnefPart.cs
Original file line number Diff line number Diff line change
Expand Up @@ -408,10 +408,8 @@ static void ExtractAttachments (TnefReader reader, BodyBuilder builder)
break;
case TnefPropertyId.AttachDisposition:
text = prop.ReadValueAsString ();
if (attachment.ContentDisposition == null)
attachment.ContentDisposition = new ContentDisposition (text);
else
attachment.ContentDisposition.Disposition = text;
if (ContentDisposition.TryParse (text, out ContentDisposition disposition))
attachment.ContentDisposition = disposition;
break;
case TnefPropertyId.AttachData:
if (attachMethod == TnefAttachMethod.EmbeddedMessage) {
Expand Down

0 comments on commit b127477

Please sign in to comment.