Skip to content

Commit

Permalink
IMAP: fix #359, handle RFC822.TEXT
Browse files Browse the repository at this point in the history
git-svn-id: https://svn.code.sf.net/p/davmail/code/trunk@3575 3d1905a2-6b24-0410-a738-b14d5a86fcbd
  • Loading branch information
mguessan committed Jun 7, 2024
1 parent bc0dfc1 commit 844680d
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/java/davmail/imap/ImapConnection.java
Original file line number Diff line number Diff line change
Expand Up @@ -902,7 +902,8 @@ private void handleFetch(ExchangeSession.Message message, int currentIndex, Stri
} catch (ParseException e) {
throw new DavMailException("EXCEPTION_INVALID_DATE", message.date);
}
} else if ("RFC822".equals(param) || param.startsWith("BODY[") || param.startsWith("BODY.PEEK[") || "RFC822.HEADER".equals(param)) {
} else if ("RFC822".equals(param) || param.startsWith("BODY[") || param.startsWith("BODY.PEEK[")
|| "RFC822.HEADER".equals(param) || "RFC822.TEXT".equals(param)) {

if (param.startsWith("BODY[") && !message.read) {
// According to IMAP RFC: The \Seen flag is implicitly set
Expand Down Expand Up @@ -1015,6 +1016,8 @@ private void handleFetch(ExchangeSession.Message message, int currentIndex, Stri
buffer.append(" RFC822");
} else if ("RFC822.HEADER".equals(param)) {
buffer.append(" RFC822.HEADER");
} else if ("RFC822.TEXT".equals(param)) {
buffer.append(" RFC822.TEXT");
} else {
buffer.append(" BODY[");
if (partIndexString != null) {
Expand Down

0 comments on commit 844680d

Please sign in to comment.