Ignore:
Timestamp:
Apr 18, 2009, 11:17:30 PM (13 years ago)
Author:
charles
Message:

(trunk) experimental support for tr_torrentSetPriority()

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/libtransmission/torrent.c

    r8244 r8254  
    15221522    assert( tr_isTorrent( tor ) );
    15231523    assert( fileIndex < tor->info.fileCount );
    1524     assert( priority == TR_PRI_LOW || priority == TR_PRI_NORMAL || priority == TR_PRI_HIGH );
     1524    assert( tr_isPriority( priority ) );
    15251525
    15261526    file = &tor->info.files[fileIndex];
     
    16911691    tr_torrentSaveResume( tor );
    16921692    tr_torrentUnlock( tor );
     1693}
     1694
     1695/***
     1696****
     1697***/
     1698
     1699tr_priority_t
     1700tr_torrentGetPriority( const tr_torrent * tor )
     1701{
     1702    assert( tr_isTorrent( tor ) );
     1703
     1704    return tor->bandwidth->priority;
     1705}
     1706
     1707void
     1708tr_torrentSetPriority( tr_torrent * tor, tr_priority_t priority )
     1709{
     1710    assert( tr_isTorrent( tor ) );
     1711    assert( tr_isPriority( priority ) );
     1712
     1713    tor->bandwidth->priority = priority;
    16931714}
    16941715
Note: See TracChangeset for help on using the changeset viewer.