Author: toad
Date: 2008-12-02 20:02:21 +0000 (Tue, 02 Dec 2008)
New Revision: 24018

Modified:
   trunk/freenet/src/freenet/node/IPDetectorPluginManager.java
Log:
If we have no non-local peers, treat it for detection purposes as if we had no 
peers.


Modified: trunk/freenet/src/freenet/node/IPDetectorPluginManager.java
===================================================================
--- trunk/freenet/src/freenet/node/IPDetectorPluginManager.java 2008-12-02 
19:46:23 UTC (rev 24017)
+++ trunk/freenet/src/freenet/node/IPDetectorPluginManager.java 2008-12-02 
20:02:21 UTC (rev 24018)
@@ -540,6 +540,7 @@
                
                // If we have no connections, and several disconnected nodes, 
we should do a
                // detection soon.
+               if(logMINOR) Logger.minor(this, "Real connections: 
"+realConnections+" disconnected "+realDisconnected);
                if(realConnections == 0 && realDisconnected > 0) {
                        if(firstTimeUrgent <= 0)
                                firstTimeUrgent = now;
@@ -559,6 +560,8 @@
                                // Detect immediately
                                detect = true;
                        }
+               } else if(realConnections == 0 && realDisconnected == 0) {
+                       return shouldDetectNoPeers(now);
                } else {
                        if(logDEBUG) Logger.minor(this, "Not urgent; 
conns="+conns.length+", peers="+peers.length);
                        firstTimeUrgent = 0;

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

Reply via email to