Update of /cvsroot/freenet/freenet/src/freenet/node
In directory sc8-pr-cvs1:/tmp/cvs-serv32717/src/freenet/node

Modified Files:
      Tag: stable
        Node.java 
Log Message:
D'oh.

Index: Node.java
===================================================================
RCS file: /cvsroot/freenet/freenet/src/freenet/node/Node.java,v
retrieving revision 1.82.2.28.2.35
retrieving revision 1.82.2.28.2.36
diff -u -w -r1.82.2.28.2.35 -r1.82.2.28.2.36
--- Node.java   15 Nov 2003 22:13:32 -0000      1.82.2.28.2.35
+++ Node.java   19 Nov 2003 16:36:33 -0000      1.82.2.28.2.36
@@ -269,11 +269,11 @@
         config.addOption("requestSendTimeCutoff", 1, 1000, 3256);
         config.addOption("successfulSendTimeCutoff", 1, 4000, 3257);
         config.addOption("doOutLimitCutoff",1,true,3258);
-        config.addOption("outLimitCutoff",1,0.8F,3259);
+        config.addOption("outLimitCutoff",1, 2.0F,3259);
         config.addOption("doOutLimitConnectCutoff",1,true,3260);
-        config.addOption("outLimitConnectCutoff",1,2.0F,3261);
+        config.addOption("outLimitConnectCutoff",1,3.0F,3261);
         config.addOption("lowLevelBWLimitFudgeFactor",1,3F/4F,3262);
-        config.addOption("lowLevelBWLimitMultiplier",1,1.3F,3263);
+        config.addOption("lowLevelBWLimitMultiplier",1,1.0F,3263);
         config.addOption("doLowLevelOutputLimiting",1,true,3264);
         config.addOption("doLowLevelInputLimiting",1,true,3265);
         // Commented out because of limited use and potential political problems i.e. 
not cross platform
@@ -2138,7 +2138,7 @@
 
         // set storage parameters
         storeSize = params.getLong("storeSize");
-        if(storeSize < (101L * (1<<20))) {
+        if(storeSize > 0 && storeSize < (101L * (1<<20))) {
             String error = "Store size insufficient to store 1MB chunks! Your 
datastore is so small that it will not be able to store 1MB chunks, the maximum size 
of a single data key that most tools insert. You will still be able to fetch them but 
your node will not be very useful to the network, and consequentially will not perform 
well. To eliminate this error increase your storeSize to at least 101M. It is 
currently "+storeSize+".";
             System.err.println(error);
             Core.logger.log(Node.class, error, Logger.ERROR);
@@ -3021,6 +3021,11 @@
         logger.log(this, "shouldCache("+(sd==null?"(null)":sd.toString())
                    +")", Logger.DEBUG);
         // FIXME: use Main.storeSize()?
+        if(storeSize == 0) {
+            logger.log(this, "shouldCache returning true because "+
+                       "storeSize == 0", Logger.DEBUG);
+            return true;
+        }
         long used = storeSize - dir.available();
         long target = (long)(storeSize * (double)minStoreFullPCache);
         if(used < target) {

_______________________________________________
cvs mailing list
[EMAIL PROTECTED]
http://dodo.freenetproject.org/cgi-bin/mailman/listinfo/cvs

Reply via email to