1
0
Fork 0
mirror of https://github.com/transmission/transmission synced 2024-12-25 17:17:31 +00:00

#811: fix r5329 error in trunk.

This commit is contained in:
Charles Kerr 2008-03-24 16:10:04 +00:00
parent 910d77ae12
commit b3663db916

View file

@ -1231,6 +1231,7 @@ setFileDND( tr_torrent * tor,
/* can't set the first piece to DND unless /* can't set the first piece to DND unless
every file using that piece is DND */ every file using that piece is DND */
firstPieceDND = dnd; firstPieceDND = dnd;
if( fileIndex > 0 ) {
for( i=fileIndex-1; firstPieceDND; --i ) { for( i=fileIndex-1; firstPieceDND; --i ) {
if( tor->info.files[i].lastPiece != firstPiece ) if( tor->info.files[i].lastPiece != firstPiece )
break; break;
@ -1238,6 +1239,7 @@ setFileDND( tr_torrent * tor,
if( !i ) if( !i )
break; break;
} }
}
/* can't set the last piece to DND unless /* can't set the last piece to DND unless
every file using that piece is DND */ every file using that piece is DND */