simple-java-mail icon indicating copy to clipboard operation
simple-java-mail copied to clipboard

EmailConverter NullPointerException getDate

Open fatjon-etemi opened this issue 2 years ago • 2 comments

Version: 7.1.1

Hi everyone,

I have got an error when trying to read the HTML Body of specific Outlook E-mails (.msg file) I would upload the file but it's not possible here.

Code:

email = EmailConverter.outlookMsgToEmail(new ByteArrayInputStream((byte[]) getValue("DOC_IMAGE")));

Stacktrace:

java.lang.NullPointerException at org.simplejavamail.outlookmessageparser.model.OutlookMessage.getDate(OutlookMessage.java:865) at org.simplejavamail.internal.outlooksupport.converter.OutlookEmailConverter.buildEmailFromOutlookMessage(OutlookEmailConverter.java:102) at org.simplejavamail.internal.outlooksupport.converter.OutlookEmailConverter.outlookMsgToEmailBuilder(OutlookEmailConverter.java:85) at org.simplejavamail.converter.EmailConverter.outlookMsgToEmailBuilder(EmailConverter.java:239) at org.simplejavamail.converter.EmailConverter.outlookMsgToEmail(EmailConverter.java:221) at org.simplejavamail.converter.EmailConverter.outlookMsgToEmail(EmailConverter.java:213)

fatjon-etemi avatar Apr 26 '22 10:04 fatjon-etemi

Is it possible for you to share the email to me personally? I would like to investigate.

bbottema avatar Jul 12 '22 13:07 bbottema

Bump

bbottema avatar Jul 28 '22 12:07 bbottema

Any update on a sample I can investigate? Will close this soon otherwise as non-actionable.

bbottema avatar Jan 24 '23 17:01 bbottema

Any update on a sample I can investigate? Will close this soon otherwise as non-actionable.

Hello, sorry for the late response. I need to search for the mail. I will respond you again on Monday.

fatjon-etemi avatar Feb 24 '23 19:02 fatjon-etemi

I found something and have sent it to you by mail.

fatjon-etemi avatar Feb 26 '23 18:02 fatjon-etemi

Thanks, I'll have a look.

bbottema avatar Feb 26 '23 21:02 bbottema

I just did a test with the .msg file you sent me, but that won't even open in Outlook itself, and it won't read in outlook-message-parser, the library used by Simple Java Mail, either:

image

image

Closing this until I have something real to go on.

bbottema avatar Oct 12 '23 12:10 bbottema