Changeset 7792
- Timestamp:
- Jan 24, 2009, 5:20:07 PM (12 years ago)
- Location:
- trunk/libtransmission
- Files:
-
- 5 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/libtransmission/handshake.c
r7770 r7792 229 229 230 230 static int tr_handshakeDone( tr_handshake * handshake, 231 intisConnected );231 tr_bool isConnected ); 232 232 233 233 enum … … 1079 1079 static int 1080 1080 fireDoneFunc( tr_handshake * handshake, 1081 intisConnected )1081 tr_bool isConnected ) 1082 1082 { 1083 1083 const uint8_t * peer_id = isConnected && handshake->havePeerID … … 1105 1105 static int 1106 1106 tr_handshakeDone( tr_handshake * handshake, 1107 intisOK )1107 tr_bool isOK ) 1108 1108 { 1109 1109 tr_bool success; -
trunk/libtransmission/handshake.h
r7658 r7792 27 27 typedef tr_bool ( *handshakeDoneCB )( struct tr_handshake * handshake, 28 28 struct tr_peerIo * io, 29 intisConnected,29 tr_bool isConnected, 30 30 const uint8_t * peerId, 31 31 void * userData ); -
trunk/libtransmission/peer-io.c
r7791 r7792 451 451 452 452 void 453 tr_peerIoRef( tr_peerIo * io ) 454 { 455 assert( tr_isPeerIo( io ) ); 453 tr_peerIoRefImpl( const char * file, int line, tr_peerIo * io ) 454 { 455 assert( tr_isPeerIo( io ) ); 456 457 dbgmsg( io, "%s:%d is incrementing the IO's refcount from %d to %d\n", 458 file, line, io->refCount, io->refCount+1 ); 456 459 457 460 ++io->refCount; … … 459 462 460 463 void 461 tr_peerIoUnref( tr_peerIo * io ) 462 { 463 assert( tr_isPeerIo( io ) ); 464 tr_peerIoUnrefImpl( const char * file, int line, tr_peerIo * io ) 465 { 466 assert( tr_isPeerIo( io ) ); 467 468 dbgmsg( io, "%s:%d is decrementing the IO's refcount from %d to %d\n", 469 file, line, io->refCount, io->refCount+1 ); 464 470 465 471 if( !--io->refCount ) … … 468 474 469 475 const tr_address* 470 tr_peerIoGetAddress( const tr_peerIo * io, 471 tr_port * port ) 476 tr_peerIoGetAddress( const tr_peerIo * io, tr_port * port ) 472 477 { 473 478 assert( tr_isPeerIo( io ) ); -
trunk/libtransmission/peer-io.h
r7790 r7792 121 121 int socket ); 122 122 123 void tr_peerIoRef ( tr_peerIo * io ); 124 125 void tr_peerIoUnref ( tr_peerIo * io ); 123 void tr_peerIoRefImpl ( const char * file, 124 int line, 125 tr_peerIo * io ); 126 127 #define tr_peerIoRef(io) tr_peerIoRefImpl( __FILE__, __LINE__, (io) ); 128 129 void tr_peerIoUnrefImpl ( const char * file, 130 int line, 131 tr_peerIo * io ); 132 133 #define tr_peerIoUnref(io) tr_peerIoUnrefImpl( __FILE__, __LINE__, (io) ); 126 134 127 135 tr_bool tr_isPeerIo ( const tr_peerIo * io ); -
trunk/libtransmission/peer-mgr.c
r7765 r7792 1161 1161 myHandshakeDoneCB( tr_handshake * handshake, 1162 1162 tr_peerIo * io, 1163 intisConnected,1163 tr_bool isConnected, 1164 1164 const uint8_t * peer_id, 1165 1165 void * vmanager ) … … 1174 1174 1175 1175 assert( io ); 1176 assert( isConnected == 0 || isConnected == 1);1176 assert( tr_isBool( ok ) ); 1177 1177 1178 1178 t = tr_peerIoHasTorrentHash( io )
Note: See TracChangeset
for help on using the changeset viewer.