fixed timing problem causing a division by zero exception

git-svn-id: https://svn.berlios.de/svnroot/repos/yacy/trunk@2287 6c8d7289-2bf4-0310-a012-ef5d649a1542
pull/1/head
orbiter 19 years ago
parent 379acb4915
commit d2bb3f442e

@ -125,7 +125,7 @@ public class yacyPeerActions {
//set the PPM
seedDB.mySeed.put(yacySeed.ISPEED, Long.toString(indexedcdiff / uptimediff));
}
sb.setConfig("totalPPM", Long.toString(indexedc / uptime));
sb.setConfig("totalPPM", Long.toString(indexedc / (uptime + 1)));
seedDB.mySeed.put(yacySeed.UPTIME, Long.toString(uptime)); // the number of minutes that the peer is up in minutes/day (moving average MA30)
seedDB.mySeed.put(yacySeed.LCOUNT, Integer.toString(sb.urlPool.loadedURL.size())); // the number of links that the peer has stored (LURL's)

Loading…
Cancel
Save