forked from premiere/premiere-libtorrent
prefer purging peer entries that are not connectable
This commit is contained in:
parent
6e7de92859
commit
1deeb98898
|
@ -1631,6 +1631,9 @@ namespace libtorrent
|
||||||
if (lhs_resume_data_source != rhs_resume_data_source)
|
if (lhs_resume_data_source != rhs_resume_data_source)
|
||||||
return lhs_resume_data_source > rhs_resume_data_source;
|
return lhs_resume_data_source > rhs_resume_data_source;
|
||||||
|
|
||||||
|
if (lhs.connectable != rhs.connectable)
|
||||||
|
return lhs.connectable < rhs.connectable;
|
||||||
|
|
||||||
// prefer peers with higher failcount
|
// prefer peers with higher failcount
|
||||||
return lhs.failcount > rhs.failcount;
|
return lhs.failcount > rhs.failcount;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue