I2P Address: [http://git.idk.i2p]

Skip to content
Snippets Groups Projects
Commit c40f8452 authored by zzz's avatar zzz
Browse files

fix good/bad calculation

parent aa749622
No related branches found
No related tags found
No related merge requests found
......@@ -129,14 +129,14 @@ class FloodfillPeerSelector extends PeerSelector {
} else {
PeerProfile prof = _context.profileOrganizer().getProfile(entry);
if (prof != null && prof.getDBHistory() != null
&& now - prof.getDBHistory().getLastStoreFailed() > NO_FAIL_STORE_GOOD
&& now - prof.getDBHistory().getLastLookupFailed() > NO_FAIL_LOOKUP_GOOD) {
&& now - prof.getDBHistory().getLastStoreFailed() < now - NO_FAIL_STORE_GOOD
&& now - prof.getDBHistory().getLastLookupFailed() < now - NO_FAIL_LOOKUP_GOOD) {
// good
rv.add(entry);
found++;
} else if (prof != null && prof.getDBHistory() != null
&& now - prof.getDBHistory().getLastStoreFailed() > NO_FAIL_STORE_OK
&& now - prof.getDBHistory().getLastLookupFailed() > NO_FAIL_LOOKUP_OK) {
&& now - prof.getDBHistory().getLastStoreFailed() < now - NO_FAIL_STORE_OK
&& now - prof.getDBHistory().getLastLookupFailed() < now - NO_FAIL_LOOKUP_OK) {
okff.add(entry);
} else {
badff.add(entry);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment