Changeset 8483


Ignore:
Timestamp:
May 22, 2009, 7:03:00 PM (12 years ago)
Author:
charles
Message:

(trunk libT) fix a couple of dead assignments, and a possible null pointer dereference, found by clang

Location:
trunk/libtransmission
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/libtransmission/bandwidth.c

    r8289 r8483  
    350350{
    351351    struct tr_band * band;
    352     size_t oldBytesLeft;
    353352
    354353    assert( tr_isBandwidth( b ) );
     
    356355
    357356    band = &b->band[dir];
    358 
    359     oldBytesLeft = band->bytesLeft;
    360357
    361358    if( band->isLimited && isPieceData )
  • trunk/libtransmission/handshake.c

    r8433 r8483  
    322322
    323323    /* This doesn't depend on whether the torrent is private. */
    324     if( tor->session->isDHTEnabled )
     324    if( tor && tor->session->isDHTEnabled )
    325325        tr_peerIoEnableDHT( handshake->io, HANDSHAKE_HAS_DHT( reserved ) );
    326326
  • trunk/libtransmission/tr-dht.c

    r8452 r8483  
    150150         * so it should be something truly random. */
    151151        tr_cryptoRandBuf( myid, 20 );
    152         have_id = TRUE;
    153152    }
    154153
Note: See TracChangeset for help on using the changeset viewer.