Changeset 11236


Ignore:
Timestamp:
Sep 19, 2010, 8:36:31 PM (12 years ago)
Author:
Longinus00
Message:

(trunk) bounds check trackerIds passed over rpc

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/libtransmission/rpcimpl.c

    r11228 r11236  
    873873            && tr_bencGetStr( pair[1], &newval )
    874874            && tr_urlIsValid( newval, -1 )
    875             && pos < n )
     875            && pos < n
     876            && pos >= 0 )
    876877        {
    877878            tr_free( trackers[pos].announce );
     
    917918    {
    918919        int64_t pos;
    919         if( tr_bencGetInt( val, &pos ) && pos < n )
     920
     921        if(    tr_bencGetInt( val, &pos )
     922            && pos < n
     923            && pos >= 0 )
    920924            tids[t++] = pos;
    921925    }
Note: See TracChangeset for help on using the changeset viewer.