Changeset 75


Ignore:
Timestamp:
Jan 31, 2006, 4:58:28 AM (15 years ago)
Author:
titer
Message:

Fixed a lame typo so the algorithm may actually work

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/libtransmission/choking.c

    r65 r75  
    133133    sortPeers( peersCanUnchoke, peersCanUnchokeCount );
    134134
    135     if( unchokedCount > c->slots )
     135    if( unchokedCount > c->slots && peersCanChokeCount > 0 )
    136136    {
    137137        int willChoke;
     
    143143                 peersCanChokeCount );
    144144    }
    145     else if( unchokedCount < c->slots )
     145    else if( unchokedCount < c->slots && peersCanUnchokeCount > 0 )
    146146    {
    147147        int willUnchoke;
     
    155155    {
    156156        if( tr_peerDownloadRate( peersCanUnchoke[peersCanUnchokeCount - 1] )
    157                 > tr_peerDownloadRate( peersCanChoke[0] ) )
     157                < tr_peerDownloadRate( peersCanChoke[0] ) )
    158158            break;
    159159
Note: See TracChangeset for help on using the changeset viewer.