Changeset 147


Ignore:
Timestamp:
Mar 12, 2006, 5:15:32 AM (16 years ago)
Author:
titer
Message:

Added tr_torrentIterate

Location:
branches/new_api/libtransmission
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • branches/new_api/libtransmission/transmission.c

    r141 r147  
    332332{
    333333    return h->torrentCount;
     334}
     335
     336void tr_torrentIterate( tr_handle_t * h, tr_callback_t func, void * d )
     337{
     338    tr_torrent_t * tor;
     339
     340    for( tor = h->torrentList; tor; tor = tor->next )
     341    {
     342        func( tor, d );
     343    }
    334344}
    335345
  • branches/new_api/libtransmission/transmission.h

    r141 r147  
    8282
    8383/***********************************************************************
     84 * tr_torrentIterate
     85 ***********************************************************************
     86 * Iterates on open torrents
     87 **********************************************************************/
     88typedef struct tr_torrent_s tr_torrent_t;
     89typedef void (*tr_callback_t) ( tr_torrent_t *, void * );
     90void tr_torrentIterate( tr_handle_t *, tr_callback_t, void * );
     91
     92/***********************************************************************
    8493 * tr_torrentRates
    8594 ***********************************************************************
     
    103112 * otherwise.
    104113 **********************************************************************/
    105 typedef struct tr_torrent_s tr_torrent_t;
    106114#define TR_EINVALID     1
    107115#define TR_EUNSUPPORTED 2
Note: See TracChangeset for help on using the changeset viewer.