Changeset 1766
- Timestamp:
- Apr 20, 2007, 11:31:49 PM (15 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/libtransmission/torrent.c
r1655 r1766 462 462 if( s->downloaded == 0 ) 463 463 { 464 s->ratio = s->uploaded == 0 ? TR_RATIO_NA : TR_RATIO_INF; 464 //if seeding without ever downloading, calculate ratio from total size 465 if( s->progress >= 1.0 ) 466 { 467 s->ratio = (float)s->uploaded / (float)inf->totalSize; 468 } 469 else 470 { 471 s->ratio = s->uploaded == 0 ? TR_RATIO_NA : TR_RATIO_INF; 472 } 465 473 } 466 474 else
Note: See TracChangeset
for help on using the changeset viewer.