From e7e103f103cc0683bba8fcdc2c067f41a662e8bd Mon Sep 17 00:00:00 2001 From: mguessan Date: Fri, 4 Sep 2009 16:01:24 +0000 Subject: [PATCH] IMAP: Improve IMAP bodystructure error logging git-svn-id: http://svn.code.sf.net/p/davmail/code/trunk@699 3d1905a2-6b24-0410-a738-b14d5a86fcbd --- src/java/davmail/imap/ImapConnection.java | 3 +++ src/java/davmailmessages.properties | 2 +- 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/src/java/davmail/imap/ImapConnection.java b/src/java/davmail/imap/ImapConnection.java index 35ff0954..40cb4840 100644 --- a/src/java/davmail/imap/ImapConnection.java +++ b/src/java/davmail/imap/ImapConnection.java @@ -615,6 +615,9 @@ public class ImapConnection extends AbstractConnection { appendBodyStructure(buffer, mimeMessage); } } catch (MessagingException me) { + DavGatewayTray.warn(me); + // dump message in log + DavGatewayTray.debug(new BundleMessage("LOG_MESSAGE", new String(baos.toByteArray()))); throw new DavMailException("EXCEPTION_INVALID_MESSAGE_CONTENT", me.getMessage()); } } diff --git a/src/java/davmailmessages.properties b/src/java/davmailmessages.properties index 38a93d4b..d304483c 100644 --- a/src/java/davmailmessages.properties +++ b/src/java/davmailmessages.properties @@ -18,7 +18,7 @@ EXCEPTION_INVALID_HEADER=Invalid header: {0} EXCEPTION_INVALID_ICS_LINE=Invalid ICS line: {0} EXCEPTION_INVALID_KEEPALIVE=Invalid Keep-Alive: {0} EXCEPTION_INVALID_MAIL_PATH=Invalid mail path: {0} -EXCEPTION_INVALID_MESSAGE_CONTENT=Invalid calendar message content: {0} +EXCEPTION_INVALID_MESSAGE_CONTENT=Invalid message content: {0} EXCEPTION_INVALID_MESSAGE_URL=Invalid message URL: {0} EXCEPTION_INVALID_RECIPIENT=Invalid recipient: {0} EXCEPTION_INVALID_REQUEST=Invalid request: {0}