mirror of
https://github.com/transmission/transmission
synced 2025-02-10 08:24:50 +00:00
(trunk libT) more of the same
This commit is contained in:
parent
5812b9f05b
commit
6d6a76d48a
1 changed files with 4 additions and 4 deletions
|
@ -170,7 +170,7 @@ tr_isPeerIo( const tr_peerIo * io )
|
||||||
{
|
{
|
||||||
return ( io != NULL )
|
return ( io != NULL )
|
||||||
&& ( io->magicNumber == MAGIC_NUMBER )
|
&& ( io->magicNumber == MAGIC_NUMBER )
|
||||||
&& ( io->refCount > 0 )
|
&& ( io->refCount >= 0 )
|
||||||
&& ( tr_isBandwidth( &io->bandwidth ) )
|
&& ( tr_isBandwidth( &io->bandwidth ) )
|
||||||
&& ( tr_isAddress( &io->addr ) );
|
&& ( tr_isAddress( &io->addr ) );
|
||||||
}
|
}
|
||||||
|
@ -454,7 +454,7 @@ tr_peerIoRefImpl( const char * file, int line, tr_peerIo * io )
|
||||||
{
|
{
|
||||||
assert( tr_isPeerIo( io ) );
|
assert( tr_isPeerIo( io ) );
|
||||||
|
|
||||||
dbgmsg( io, "%s:%d is incrementing the IO's refcount from %d to %d\n",
|
dbgmsg( io, "%s:%d is incrementing the IO's refcount from %d to %d",
|
||||||
file, line, io->refCount, io->refCount+1 );
|
file, line, io->refCount, io->refCount+1 );
|
||||||
|
|
||||||
++io->refCount;
|
++io->refCount;
|
||||||
|
@ -465,8 +465,8 @@ tr_peerIoUnrefImpl( const char * file, int line, tr_peerIo * io )
|
||||||
{
|
{
|
||||||
assert( tr_isPeerIo( io ) );
|
assert( tr_isPeerIo( io ) );
|
||||||
|
|
||||||
dbgmsg( io, "%s:%d is decrementing the IO's refcount from %d to %d\n",
|
dbgmsg( io, "%s:%d is decrementing the IO's refcount from %d to %d",
|
||||||
file, line, io->refCount, io->refCount+1 );
|
file, line, io->refCount, io->refCount-1 );
|
||||||
|
|
||||||
if( !--io->refCount )
|
if( !--io->refCount )
|
||||||
tr_peerIoFree( io );
|
tr_peerIoFree( io );
|
||||||
|
|
Loading…
Reference in a new issue