Changeset 11918


Ignore:
Timestamp:
Feb 18, 2011, 12:24:48 AM (11 years ago)
Author:
jch
Message:

Propagate uTP and ut_holepunch information over PEX.

Location:
trunk/libtransmission
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/libtransmission/peer-mgr.c

    r11903 r11918  
    19591959        }
    19601960
     1961        /* In principle, this flag specifies whether the peer groks uTP,
     1962           not whether it's currently connected over uTP. */
     1963        if( io->utp_socket )
     1964            atom->flags |= ADDED_F_UTP_FLAGS;
     1965
    19611966        if( atom->flags2 & MYFLAG_BANNED )
    19621967        {
  • trunk/libtransmission/peer-msgs.c

    r11898 r11918  
    939939            msgs->ut_metadata_id = (uint8_t) i;
    940940            dbgmsg( msgs, "msgs->ut_metadata_id is %d", (int)msgs->ut_metadata_id );
     941        }
     942        /* We don't support ut_holepunch yet, but we might as well
     943           propagate this information over PEX. */
     944        if( tr_bencDictFindInt( sub, "ut_holepunch", &i ) ) {
     945            if( i != 0 )
     946                pex.flags |= ADDED_F_HOLEPUNCH;
    941947        }
    942948    }
Note: See TracChangeset for help on using the changeset viewer.