[jboss-jira] [JBoss JIRA] Closed: (JBMAIL-241) MailListenerChainService.processMail doesn't handle null message properly.
Andrew Oliver (JIRA)
jira-events at jboss.com
Wed Dec 13 19:27:21 EST 2006
[ http://jira.jboss.com/jira/browse/JBMAIL-241?page=all ]
Andrew Oliver closed JBMAIL-241.
--------------------------------
Fix Version/s: (was: 1.0-RC1)
Resolution: Won't Fix
Assignee: (was: Andrew Oliver)
> MailListenerChainService.processMail doesn't handle null message properly.
> --------------------------------------------------------------------------
>
> Key: JBMAIL-241
> URL: http://jira.jboss.com/jira/browse/JBMAIL-241
> Project: JBoss Mail ** Closed - moved to http://buni.org **
> Issue Type: Patch
> Security Level: Public(Everyone can see)
> Affects Versions: 1.0-M2, 1.0-M3, 1.0-M4, 1.0-M5, 1.0-RC1
> Environment: All
> Reporter: David Fuelling
> Original Estimate: 15 minutes
> Remaining Estimate: 15 minutes
>
> If a given mail listner (i.e., JMSMailListener) completely processes a mail, the function contract stipulates that the listener should return 'null'. Unfortunately, not all of the JBCS listeners deal well with a null message, so the MailListenerChainService should detect if a null message is received from any listener. If so, the listener should abort the processing of the remaining listeners.
> The Patch is:
> Index: MailListenerChainService.java
> ===================================================================
> RCS file: /cvsroot/jboss/jboss-mail/src/java/org/jboss/mail/MailListenerChainService.java,v
> retrieving revision 1.4
> diff -u -r1.4 MailListenerChainService.java
> --- MailListenerChainService.java 31 Mar 2006 22:34:51 -0000 1.4
> +++ MailListenerChainService.java 7 Jul 2006 15:03:02 -0000
> @@ -187,6 +187,8 @@
> for (int i = 0; i < listeners.size(); i++) {
> MailListener listener = ((PositionedListener) listeners.get(i)).listener;
> msg = listener.send(msg);
> + if(msg == null)
> + break;
> }
> return msg;
> }
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.jboss.com/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
More information about the jboss-jira
mailing list