james-server-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From b...@apache.org
Subject svn commit: r365622 - /james/server/trunk/src/java/org/apache/james/transport/mailets/RemoteDelivery.java
Date Tue, 03 Jan 2006 12:57:59 GMT
Author: bago
Date: Tue Jan  3 04:57:54 2006
New Revision: 365622

URL: http://svn.apache.org/viewcvs?rev=365622&view=rev
Log:
Workaround to avoid ArrayIndexOutOfBoundsException when the number of retries in RemoteDelivery
config is decreased and delayed mails exists in spool (JAMES-316)

Modified:
    james/server/trunk/src/java/org/apache/james/transport/mailets/RemoteDelivery.java

Modified: james/server/trunk/src/java/org/apache/james/transport/mailets/RemoteDelivery.java
URL: http://svn.apache.org/viewcvs/james/server/trunk/src/java/org/apache/james/transport/mailets/RemoteDelivery.java?rev=365622&r1=365621&r2=365622&view=diff
==============================================================================
--- james/server/trunk/src/java/org/apache/james/transport/mailets/RemoteDelivery.java (original)
+++ james/server/trunk/src/java/org/apache/james/transport/mailets/RemoteDelivery.java Tue
Jan  3 04:57:54 2006
@@ -1152,6 +1152,9 @@
      * @return the next delay time to use, given the retry count
      **/
     private long getNextDelay (int retry_count) {
+        if (retry_count > delayTimes.length) {
+            return DEFAULT_DELAY_TIME;
+        }
         return delayTimes[retry_count-1];
     }
 



---------------------------------------------------------------------
To unsubscribe, e-mail: server-dev-unsubscribe@james.apache.org
For additional commands, e-mail: server-dev-help@james.apache.org


Mime
View raw message