Author: toad
Date: 2006-02-11 17:28:31 +0000 (Sat, 11 Feb 2006)
New Revision: 8013

Modified:
   trunk/freenet/src/freenet/client/async/SplitFileFetcher.java
   trunk/freenet/src/freenet/node/Version.java
Log:
441:
Update more while scheduling blocks for a fetch.
This avoids the seemingly random behaviour at present (only update when a block 
has been fetched not from store; this makes sense, but not while scheduling!).

Modified: trunk/freenet/src/freenet/client/async/SplitFileFetcher.java
===================================================================
--- trunk/freenet/src/freenet/client/async/SplitFileFetcher.java        
2006-02-11 16:48:27 UTC (rev 8012)
+++ trunk/freenet/src/freenet/client/async/SplitFileFetcher.java        
2006-02-11 17:28:31 UTC (rev 8013)
@@ -220,8 +220,10 @@
        public void schedule() {
                for(int i=0;i<segments.length;i++) {
                        segments[i].schedule();
+                       // Update after each segment is scheduled.
+                       // The client may get updates from individual fetches 
anyway; make it more predictable.
+                       parent.notifyClients();
                }
-               parent.notifyClients();
        }

        public void cancel() {

Modified: trunk/freenet/src/freenet/node/Version.java
===================================================================
--- trunk/freenet/src/freenet/node/Version.java 2006-02-11 16:48:27 UTC (rev 
8012)
+++ trunk/freenet/src/freenet/node/Version.java 2006-02-11 17:28:31 UTC (rev 
8013)
@@ -20,7 +20,7 @@
        public static final String protocolVersion = "1.0";

        /** The build number of the current revision */
-       private static final int buildNumber = 440;
+       private static final int buildNumber = 441;

        /** Oldest build of Fred we will talk to */
        private static final int lastGoodBuild = 403;


Reply via email to