Decode subject before unfolding

This commit is contained in:
M66B 2020-02-05 09:45:52 +01:00
parent 9291dff9f7
commit 0cfd691017
1 changed files with 1 additions and 1 deletions

View File

@ -995,9 +995,9 @@ public class MessageHelper {
if (subject == null) if (subject == null)
return null; return null;
subject = new String(subject.getBytes(StandardCharsets.ISO_8859_1));
subject = subject.replaceAll("\\?=\\r?\\n\\s+=\\?", "\\?==\\?"); subject = subject.replaceAll("\\?=\\r?\\n\\s+=\\?", "\\?==\\?");
subject = MimeUtility.unfold(subject); subject = MimeUtility.unfold(subject);
subject = new String(subject.getBytes(StandardCharsets.ISO_8859_1));
subject = decodeMime(subject); subject = decodeMime(subject);
return subject; return subject;