bugfix for received number in transferRWI

git-svn-id: https://svn.berlios.de/svnroot/repos/yacy/trunk@2989 6c8d7289-2bf4-0310-a012-ef5d649a1542
This commit is contained in:
orbiter 2006-11-20 15:38:11 +00:00
parent f4b547dc13
commit d66dbd0d65

View File

@ -203,7 +203,7 @@ public final class transferRWI {
unknownURLs.append(",").append((String) it.next());
}
if (unknownURLs.length() > 0) { unknownURLs.delete(0, 1); }
if (wordhashes.length == 0) {
if ((wordhashes.length == 0) || (received == 0)) {
sb.getLog().logInfo("Received 0 RWIs from " + otherPeerName + ", processed in " + (System.currentTimeMillis() - startProcess) + " milliseconds, requesting " + unknownURL.size() + " URLs");
} else {
final double avdist = (yacyDHTAction.dhtDistance(yacyCore.seedDB.mySeed.hash, wordhashes[0]) + yacyDHTAction.dhtDistance(yacyCore.seedDB.mySeed.hash, wordhashes[received - 1])) / 2.0;