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

Compile before you commit

This commit is contained in:
Eric Petit 2007-01-21 07:32:31 +00:00
parent 09c277257b
commit 1634595bb0
3 changed files with 3 additions and 8 deletions

View file

@ -484,11 +484,6 @@ float tr_peerUploadRate( tr_peer_t * peer )
return tr_rcRate( peer->upload ); return tr_rcRate( peer->upload );
} }
int tr_peerIsInterested ( tr_peer_t * peer )
{
return peer->peerInterested;
}
void tr_peerChoke( tr_peer_t * peer ) void tr_peerChoke( tr_peer_t * peer )
{ {
sendChoke( peer, 1 ); sendChoke( peer, 1 );

View file

@ -48,7 +48,6 @@ int tr_peerPort ( tr_peer_t * );
uint8_t * tr_peerBitfield ( tr_peer_t * ); uint8_t * tr_peerBitfield ( tr_peer_t * );
float tr_peerDownloadRate ( tr_peer_t * ); float tr_peerDownloadRate ( tr_peer_t * );
float tr_peerUploadRate ( tr_peer_t * ); float tr_peerUploadRate ( tr_peer_t * );
int tr_peerIsInterested ( tr_peer_t * );
void tr_peerChoke ( tr_peer_t * ); void tr_peerChoke ( tr_peer_t * );
void tr_peerUnchoke ( tr_peer_t * ); void tr_peerUnchoke ( tr_peer_t * );
uint64_t tr_peerLastChoke ( tr_peer_t * ); uint64_t tr_peerLastChoke ( tr_peer_t * );

View file

@ -428,11 +428,12 @@ tr_peer_stat_t * tr_torrentPeers( tr_torrent_t * tor, int * peerCount )
peers[i].progress = tr_peerProgress( peer ); peers[i].progress = tr_peerProgress( peer );
peers[i].port = tr_peerPort( peer ); peers[i].port = tr_peerPort( peer );
if( ( peers[i].isDownloading = tr_peerIsUnchoked( peer ) ) ) if( ( peers[i].isDownloading = !tr_peerAmChoking( peer ) ) )
{ {
peers[i].uploadToRate = tr_peerUploadRate( peer ); peers[i].uploadToRate = tr_peerUploadRate( peer );
} }
if( ( peers[i].isUploading = !tr_peerIsChoking( peer ) ) ) if( ( peers[i].isUploading = ( tr_peerAmInterested( peer ) &&
!tr_peerIsChoking( peer ) ) ) )
{ {
peers[i].downloadFromRate = tr_peerDownloadRate( peer ); peers[i].downloadFromRate = tr_peerDownloadRate( peer );
} }