Author: toad
Date: 2009-04-18 13:13:29 +0000 (Sat, 18 Apr 2009)
New Revision: 26959

Modified:
   trunk/freenet/src/freenet/client/async/USKManager.java
Log:
Temporary background fetchers started by USK fetches had pollForever = true, 
hence were running forever (until dropped out of the LRU); a /-1/ could thus 
run for a *VERY* long time, and would never call the callback because we don't 
call callbacks if pollForever=true.


Modified: trunk/freenet/src/freenet/client/async/USKManager.java
===================================================================
--- trunk/freenet/src/freenet/client/async/USKManager.java      2009-04-18 
13:01:31 UTC (rev 26958)
+++ trunk/freenet/src/freenet/client/async/USKManager.java      2009-04-18 
13:13:29 UTC (rev 26959)
@@ -41,6 +41,7 @@
        /** Backgrounded USKFetchers by USK. */
        final HashMap<USK, USKFetcher> backgroundFetchersByClearUSK;
        
+       /** These must be TEMPORARY, that is, they must NOT poll forever! */
        final LRUQueue<USK> temporaryBackgroundFetchersLRU;
        
        final FetchContext backgroundFetchContext;
@@ -126,7 +127,7 @@
 //                     }
                        USKFetcher f = backgroundFetchersByClearUSK.get(clear);
                        if(f == null) {
-                               f = new USKFetcher(usk, this, 
backgroundFetchContext, new USKFetcherWrapper(usk, 
RequestStarter.UPDATE_PRIORITY_CLASS, this), 3, true, false);
+                               f = new USKFetcher(usk, this, 
backgroundFetchContext, new USKFetcherWrapper(usk, 
RequestStarter.UPDATE_PRIORITY_CLASS, this), 3, false, false);
                                sched = f;
                                backgroundFetchersByClearUSK.put(clear, f);
                        }

_______________________________________________
cvs mailing list
[email protected]
http://emu.freenetproject.org/cgi-bin/mailman/listinfo/cvs

Reply via email to