Author: j16sdiz
Date: 2009-04-07 15:05:11 +0000 (Tue, 07 Apr 2009)
New Revision: 26604
Modified:
trunk/freenet/src/freenet/crypt/Yarrow.java
Log:
Count time only in DEBUG mode
System.currentTimeMillis() is slow, and we are in synchronized{}
Modified: trunk/freenet/src/freenet/crypt/Yarrow.java
===================================================================
--- trunk/freenet/src/freenet/crypt/Yarrow.java 2009-04-07 15:04:51 UTC (rev
26603)
+++ trunk/freenet/src/freenet/crypt/Yarrow.java 2009-04-07 15:05:11 UTC (rev
26604)
@@ -648,9 +648,11 @@
rekey(tmp);
Arrays.fill(v0, (byte) 0); // blank out for security
fast_entropy = 0;
+ if (DEBUG) {
long endTime = System.currentTimeMillis();
if(endTime - startTime > 5000)
Logger.normal(this, "Fast pool reseed took " + (endTime
- startTime) + "ms");
+ }
}
private void slow_pool_reseed() {
_______________________________________________
cvs mailing list
[email protected]
http://emu.freenetproject.org/cgi-bin/mailman/listinfo/cvs