Changeset 8148


Ignore:
Timestamp:
Apr 5, 2009, 3:37:45 PM (12 years ago)
Author:
charles
Message:

(trunk) fix another rpc seed-ratio problem reported by livings

Location:
trunk
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/doc/rpc-spec.txt

    r8146 r8148  
    378378   "rpc-version"              | number     the current RPC API version
    379379   "rpc-version-minimum"      | number     the minimum RPC API version supported
     380   "seedRatioLimit"           | 'double'   the default seed ratio for torrents to use
     381   "seedRatioLimited"         | 'boolean'  true if seedRatioLimit is honored by default
    380382   "speed-limit-down"         | number     max global download speed (in K/s)
    381383   "speed-limit-down-enabled" | 'boolean'  true means enabled
  • trunk/libtransmission/rpcimpl.c

    r8132 r8148  
    743743        if( tr_bencDictFindBool( args_in, "uploadLimited", &boolVal ) )
    744744            tr_torrentUseSpeedLimit( tor, TR_UP, boolVal );
    745         if( tr_bencDictFindReal( args_in, "ratio-limit", &d ) )
    746             tr_torrentSetRatioLimit( tor, d );
    747         if( tr_bencDictFindInt( args_in, "ratio-limit-mode", &tmp ) )
    748             tr_torrentSetRatioMode( tor, tmp );
    749745        if( tr_bencDictFindReal( args_in, "seedRatioLimit", &d ) )
    750746            tr_torrentSetRatioLimit( tor, d );
     
    10681064    if( tr_bencDictFindBool( args_in, "speed-limit-up-enabled", &boolVal ) )
    10691065        tr_sessionLimitSpeed( session, TR_UP, boolVal );
    1070     if( tr_bencDictFindReal( args_in, "ratio-limit", &d ) )
    1071         tr_sessionSetRatioLimit( session, d );
    1072     if( tr_bencDictFindBool( args_in, "ratio-limit-enabled", &boolVal ) )
    1073         tr_sessionSetRatioLimited( session, boolVal );
    10741066    if( tr_bencDictFindStr( args_in, "encryption", &str ) ) {
    10751067        if( !strcmp( str, "required" ) )
     
    11671159    tr_bencDictAddInt ( d, "speed-limit-down", tr_sessionGetSpeedLimit( s, TR_DOWN ) );
    11681160    tr_bencDictAddBool( d, "speed-limit-down-enabled", tr_sessionIsSpeedLimited( s, TR_DOWN ) );
    1169     tr_bencDictAddReal( d, "ratio-limit", tr_sessionGetRatioLimit( s ) );
    1170     tr_bencDictAddBool( d, "ratio-limit-enabled", tr_sessionIsRatioLimited( s ) );
    11711161    tr_bencDictAddStr ( d, "version", LONG_VERSION_STRING );
    11721162    switch( tr_sessionGetEncryption( s ) ) {
Note: See TracChangeset for help on using the changeset viewer.