Пример #1
0
static void
saveIdleLimits( tr_benc * dict, const tr_torrent * tor )
{
    tr_benc * d = tr_bencDictAddDict( dict, KEY_IDLELIMIT, 2 );
    tr_bencDictAddInt( d, KEY_IDLELIMIT_MINS, tr_torrentGetIdleLimit( tor ) );
    tr_bencDictAddInt( d, KEY_IDLELIMIT_MODE, tr_torrentGetIdleMode( tor ) );
}
Пример #2
0
static void
saveIdleLimits (tr_variant * dict, tr_torrent * tor)
{
  tr_variant * d = tr_variantDictAddDict (dict, TR_KEY_idle_limit, 2);
  tr_variantDictAddInt (d, TR_KEY_idle_limit, tr_torrentGetIdleLimit (tor));
  tr_variantDictAddInt (d, TR_KEY_idle_mode, tr_torrentGetIdleMode (tor));
}