1
0
Fork 0
mirror of https://github.com/transmission/transmission synced 2024-12-25 01:03:01 +00:00

when seeding, instead of giving the the ratio as N/A, give uploaded/torrent_size (Waldorf_)

This commit is contained in:
Charles Kerr 2007-10-18 20:42:39 +00:00
parent 78b5c81253
commit 6a3a61716b

View file

@ -773,7 +773,8 @@ tr_torrentStat( tr_torrent * tor )
tr_bitfieldFree( available );
}
s->ratio = s->downloadedEver ? s->uploadedEver / (float)s->downloadedEver
s->ratio = ( s->downloadedEver || s->haveValid )
? s->uploadedEver / (float)(MAX(s->downloadedEver,s->haveValid))
: TR_RATIO_NA;
tr_torrentUnlock( tor );