Changeset 11676


Ignore:
Timestamp:
Jan 15, 2011, 4:25:24 PM (11 years ago)
Author:
jch
Message:

Make the peer-congestion-algorithm preference visible.

When I first implemented this code, I made the preference hidden --
unless you set it yourself, it will not appear in the sttings file.
Now that it's been documented and advertised, make it visible.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/libtransmission/session.c

    r11654 r11676  
    350350    tr_bencDictAddInt ( d, TR_PREFS_KEY_PEER_PORT_RANDOM_HIGH,    s->randomPortHigh );
    351351    tr_bencDictAddInt ( d, TR_PREFS_KEY_PEER_SOCKET_TOS,          s->peerSocketTOS );
    352     if(s->peer_congestion_algorithm && s->peer_congestion_algorithm[0])
    353         tr_bencDictAddStr ( d, TR_PREFS_KEY_PEER_CONGESTION_ALGORITHM, s->peer_congestion_algorithm );
     352    tr_bencDictAddStr ( d, TR_PREFS_KEY_PEER_CONGESTION_ALGORITHM, s->peer_congestion_algorithm );
    354353    tr_bencDictAddBool( d, TR_PREFS_KEY_PEX_ENABLED,              s->isPexEnabled );
    355354    tr_bencDictAddBool( d, TR_PREFS_KEY_PORT_FORWARDING,          tr_sessionIsPortForwardingEnabled( s ) );
     
    724723    if( tr_bencDictFindStr( settings, TR_PREFS_KEY_PEER_CONGESTION_ALGORITHM, &str ) )
    725724        session->peer_congestion_algorithm = tr_strdup(str);
     725    else
     726        session->peer_congestion_algorithm = tr_strdup("");
    726727    if( tr_bencDictFindBool( settings, TR_PREFS_KEY_BLOCKLIST_ENABLED, &boolVal ) )
    727728        tr_blocklistSetEnabled( session, boolVal );
Note: See TracChangeset for help on using the changeset viewer.