*) fixed existing protection against divbyzero and removed the new one

git-svn-id: https://svn.berlios.de/svnroot/repos/yacy/trunk@2530 6c8d7289-2bf4-0310-a012-ef5d649a1542
This commit is contained in:
auron_x 2006-09-08 23:43:30 +00:00
parent 94d7ced900
commit 06b1365066

View File

@ -130,8 +130,8 @@ public class yacyPeerActions {
//set the PPM
seedDB.mySeed.put(yacySeed.ISPEED, Long.toString(Math.round((float)indexedcdiff / ((float)uptimediff/60f))));
}
if(uptime > 0)
sb.setConfig("totalPPM", Long.toString(indexedc / (1 + (uptime/60))));
if(uptime > 60)
sb.setConfig("totalPPM", Long.toString(indexedc / (uptime/60)));
else
sb.setConfig("totalPPM", Long.toString(indexedc / 1)); //no division by zero