Author: toad
Date: 2008-07-17 21:35:23 +0000 (Thu, 17 Jul 2008)
New Revision: 21191

Modified:
   branches/db4o/freenet/src/freenet/client/async/BaseSingleFileFetcher.java
Log:
Deactivation, activation.

Modified: 
branches/db4o/freenet/src/freenet/client/async/BaseSingleFileFetcher.java
===================================================================
--- branches/db4o/freenet/src/freenet/client/async/BaseSingleFileFetcher.java   
2008-07-17 21:33:20 UTC (rev 21190)
+++ branches/db4o/freenet/src/freenet/client/async/BaseSingleFileFetcher.java   
2008-07-17 21:35:23 UTC (rev 21191)
@@ -174,8 +174,10 @@
        }

        public void onGotKey(Key key, KeyBlock block, ObjectContainer 
container, ClientContext context) {
-               if(persistent)
-                       container.activate(this, 2);
+               if(persistent) {
+                       container.activate(this, 1);
+                       container.activate(key, 5);
+               }
                synchronized(this) {
                        chosen = true;
                        finished = true;
@@ -194,6 +196,8 @@
                        Logger.error(this, "onGotKey("+key+","+block+") got 
"+e+" for "+this, e);
                        // FIXME if we get rid of the direct route this must 
call onFailure()
                }
+               if(persistent)
+                       container.deactivate(this, 1);
        }




Reply via email to