Changeset 8215


Ignore:
Timestamp:
Apr 11, 2009, 3:48:58 PM (13 years ago)
Author:
charles
Message:

(trunk libT) add more tests to verify r8214

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/libtransmission/torrent.c

    r8214 r8215  
    404404    firstFiles = tr_new( int, inf->pieceCount );
    405405    for( p=f=0; p<inf->pieceCount; ++p ) {
    406         if( inf->files[f].lastPiece < p )
     406        while( inf->files[f].lastPiece < p )
    407407            ++f;
    408408        firstFiles[p] = f;
    409409    }
    410 
    411410
    412411#if 0
     
    418417        if( f > 0 )
    419418            assert( inf->files[f-1].lastPiece < p );
     419        for( f=0; f<inf->fileCount; ++f )
     420            if( pieceHasFile( p, &inf->files[f] ) )
     421                break;
     422        assert( (int)f == firstFiles[p] );
    420423    }
    421424#endif
Note: See TracChangeset for help on using the changeset viewer.