Author: toad
Date: 2008-06-21 16:27:29 +0000 (Sat, 21 Jun 2008)
New Revision: 20587

Modified:
   branches/db4o/freenet/src/freenet/client/FECQueue.java
Log:
Fix another ArrayIndexOutOfBoundsException

Modified: branches/db4o/freenet/src/freenet/client/FECQueue.java
===================================================================
--- branches/db4o/freenet/src/freenet/client/FECQueue.java      2008-06-21 
16:19:34 UTC (rev 20586)
+++ branches/db4o/freenet/src/freenet/client/FECQueue.java      2008-06-21 
16:27:29 UTC (rev 20587)
@@ -217,7 +217,7 @@
                                                                        
continue;
                                                                }
                                                                boolean added = 
false;
-                                                               
for(ListIterator it = persistentQueueCache[j].listIterator();it.hasNext();) {
+                                                               
for(ListIterator it = persistentQueueCache[prio].listIterator();it.hasNext();) {
                                                                        FECJob 
cmp = (FECJob) it.next();
                                                                        
if(cmp.addedTime >= job.addedTime) {
                                                                                
it.previous();
@@ -227,7 +227,7 @@
                                                                                
break;
                                                                        }
                                                                }
-                                                               if(!added) 
persistentQueueCache[j].addLast(job);
+                                                               if(!added) 
persistentQueueCache[prio].addLast(job);
                                                        }
                                                }
                                        }


Reply via email to