mirror of
https://github.com/transmission/transmission
synced 2024-12-26 17:47:37 +00:00
(trunk libT) #2489: stricter checking of fringe cases in tr_torrentSetAnnounceList()
This commit is contained in:
parent
e66f8d06d2
commit
fe2d851e5b
1 changed files with 2 additions and 4 deletions
|
@ -2029,10 +2029,8 @@ tr_torrentSetAnnounceList( tr_torrent * tor,
|
|||
/* look for duplicates */
|
||||
for( i=0; i<trackerCount; ++i )
|
||||
for( j=0; j<trackerCount; ++j )
|
||||
if( ( i != j )
|
||||
&& ( trackers[i].tier == trackers[j].tier)
|
||||
&& ( !strcmp( trackers[i].announce, trackers[j].announce ) ) )
|
||||
return TR_ANNOUNCE_LIST_HAS_DUPLICATES;
|
||||
if( ( i != j ) && ( !strcmp( trackers[i].announce, trackers[j].announce ) ) )
|
||||
return TR_ANNOUNCE_LIST_HAS_DUPLICATES;
|
||||
|
||||
/* save to the .torrent file */
|
||||
if( !tr_bencLoadFile( &metainfo, TR_FMT_BENC, tor->info.torrent ) )
|
||||
|
|
Loading…
Reference in a new issue