Ignore:
Timestamp:
Oct 25, 2009, 6:49:20 PM (13 years ago)
Author:
livings124
Message:

on second thought, the other UI's might want this value sooner or later, and it's cheaper to calculate it in the stat function

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/libtransmission/torrent.c

    r9403 r9404  
    10241024            break;
    10251025    }
     1026   
     1027    if( !checkSeedRatio || s->ratio >= seedRatio || s->ratio == TR_RATIO_INF )
     1028        s->percentRatio = 1.0;
     1029    else if( s->ratio == TR_RATIO_NA )
     1030        s->percentRatio = 0.0;
     1031    else
     1032        s->percentRatio = s->ratio / seedRatio;
    10261033
    10271034    tr_torrentUnlock( tor );
Note: See TracChangeset for help on using the changeset viewer.