Uploaded image for project: '{RETIRED} XWiki Mail Sender Plugin'
  1. {RETIRED} XWiki Mail Sender Plugin
  2. XPMAIL-24

If there is an exception while sending mail which has no message (NPE) another exception is thrown hiding the real one.

    XMLWordPrintable

Details

    • Bug
    • Resolution: Fixed
    • Major
    • 1.14
    • 1.13
    • Plugin
    • None

    Description

      When an NPE or other exception with no message is thrown, you can't see the stack trace because it is supposed to be caught and the message put in the context but if there is no message, the catch block throws an NPE which hides the stack trace of the original exception.
      Failure trying to put a non-existant message into the context:

      Caused by: java.lang.NullPointerException
      	at java.util.Hashtable.put(Hashtable.java:394)
      	at com.xpn.xwiki.plugin.mailsender.MailSenderPluginApi.sendMail(MailSenderPluginApi.java:195)
      	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
      

      Attachments

        Activity

          People

            calebjamesdelisle CalebJamesDeLisle
            calebjamesdelisle CalebJamesDeLisle
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: