Update of /cvsroot/freenet/freenet/src/freenet/node/rt
In directory sc8-pr-cvs1:/tmp/cvs-serv25430/src/freenet/node/rt
Modified Files:
NGRouting.java DecayingRunningAverage.java
Log Message:
6296:
A few more Eclipse warning fixes, slightly functional this time - use our built-in URL
codecs, rather than the deprecated java ones, for example, and catch their exceptions.
Add support for deprecated options - which won't be written out when generating a
config, but will be recognized if set. bandwidthLimit and averageBandwidthLimit are
the first.
Change way we handle deprecated bandwidthLimit option, hopefully fix constant 100%
load.
Remove unused method NGRouting.transferFailed().
Index: NGRouting.java
===================================================================
RCS file: /cvsroot/freenet/freenet/src/freenet/node/rt/NGRouting.java,v
retrieving revision 1.15
retrieving revision 1.16
diff -u -w -r1.15 -r1.16
--- NGRouting.java 31 Oct 2003 20:08:11 -0000 1.15
+++ NGRouting.java 1 Nov 2003 15:13:35 -0000 1.16
@@ -126,10 +126,6 @@
// ignore, see message*
}
- public void transferFailed() {
- // ignore, see message*
- }
-
public void verityFailed() {
// Called if transfer fails in initialization
// So we haven't actually transferred anything except the storables
@@ -166,9 +162,9 @@
long now = System.currentTimeMillis();
long diff = now - lastTime;
if(diff < 0 || diff > 3600*1000) {
- Core.logger.log(this, "transferFailed("+time+","+htl+","+size+" on
"+this+
+ Core.logger.log(this, "transferFailed("+time+","+htl+","+size+") on
"+this+
" got unreasonable time: "+diff+" (now="+now+",
lastTime="+
- lastTime, Logger.NORMAL);
+ lastTime+")", Logger.NORMAL);
}
if(diff > 0 && diff < 3600*1000)
last.transferFailed(key, diff, size);
Index: DecayingRunningAverage.java
===================================================================
RCS file: /cvsroot/freenet/freenet/src/freenet/node/rt/DecayingRunningAverage.java,v
retrieving revision 1.7
retrieving revision 1.8
diff -u -w -r1.7 -r1.8
--- DecayingRunningAverage.java 31 Oct 2003 19:21:20 -0000 1.7
+++ DecayingRunningAverage.java 1 Nov 2003 15:13:35 -0000 1.8
@@ -20,7 +20,7 @@
this.decayFactor = decayFactor;
this.currentVal = dis.readDouble();
// hack to correct data - to be removed. edt
- if(currentVal<0 || currentVal>3600000) {
+ if(currentVal<0 || currentVal>(3600*1000)) {
Core.logger.log(this, "reset "+currentVal,
new Exception("debug"),
Logger.NORMAL);
_______________________________________________
cvs mailing list
[EMAIL PROTECTED]
http://dodo.freenetproject.org/cgi-bin/mailman/listinfo/cvs