Ignore:
Timestamp:
Jan 11, 2009, 5:02:04 PM (13 years ago)
Author:
charles
Message:

(trunk libT) win32 portability patch from Alexey

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/libtransmission/torrent.h

    r7632 r7663  
    197197
    198198/* get the index of this piece's first block */
    199 static inline tr_block_index_t
     199static TR_INLINE tr_block_index_t
    200200tr_torPieceFirstBlock( const tr_torrent * tor, const tr_piece_index_t piece )
    201201{
     
    204204
    205205/* what piece index is this block in? */
    206 static inline tr_piece_index_t
     206static TR_INLINE tr_piece_index_t
    207207tr_torBlockPiece( const tr_torrent * tor, const tr_block_index_t block )
    208208{
     
    211211
    212212/* how many blocks are in this piece? */
    213 static inline uint32_t
     213static TR_INLINE uint32_t
    214214tr_torPieceCountBlocks( const tr_torrent * tor, const tr_piece_index_t piece )
    215215{
     
    219219
    220220/* how many bytes are in this piece? */
    221 static inline uint32_t
     221static TR_INLINE uint32_t
    222222tr_torPieceCountBytes( const tr_torrent * tor, const tr_piece_index_t piece )
    223223{
     
    227227
    228228/* how many bytes are in this block? */
    229 static inline uint32_t
     229static TR_INLINE uint32_t
    230230tr_torBlockCountBytes( const tr_torrent * tor, const tr_block_index_t block )
    231231{
     
    234234}
    235235
    236 static inline void tr_torrentLock( const tr_torrent * tor )
     236static TR_INLINE void tr_torrentLock( const tr_torrent * tor )
    237237{
    238238    tr_globalLock( tor->session );
    239239}
    240240
    241 static inline void tr_torrentUnlock( const tr_torrent * tor )
     241static TR_INLINE void tr_torrentUnlock( const tr_torrent * tor )
    242242{
    243243    tr_globalUnlock( tor->session );
    244244}
    245245
    246 static inline tr_bool
     246static TR_INLINE tr_bool
    247247tr_torrentExists( const tr_session * session, const uint8_t *   torrentHash )
    248248{
     
    250250}
    251251
    252 static inline tr_bool
     252static TR_INLINE tr_bool
    253253tr_torrentIsSeed( const tr_torrent * tor )
    254254{
     
    256256}
    257257
    258 static inline tr_bool tr_torrentIsPrivate( const tr_torrent * tor )
     258static TR_INLINE tr_bool tr_torrentIsPrivate( const tr_torrent * tor )
    259259{
    260260    return ( tor != NULL ) && tor->info.isPrivate;
    261261}
    262262
    263 static inline tr_bool tr_torrentAllowsPex( const tr_torrent * tor )
     263static TR_INLINE tr_bool tr_torrentAllowsPex( const tr_torrent * tor )
    264264{
    265265    return ( tor != NULL  ) && tor->session->isPexEnabled && !tr_torrentIsPrivate( tor );
    266266}
    267267
    268 static inline tr_bool tr_torrentIsPieceChecked( const tr_torrent  * tor, tr_piece_index_t i )
     268static TR_INLINE tr_bool tr_torrentIsPieceChecked( const tr_torrent  * tor, tr_piece_index_t i )
    269269{
    270270    return tr_bitfieldHas( &tor->checkedPieces, i );
Note: See TracChangeset for help on using the changeset viewer.