small cleanup when determining if two announce URLs differ only by scheme

This commit is contained in:
Mitchell Livingston 2011-04-03 03:25:13 +00:00
parent 5bee93361b
commit 3e451b2bf9
1 changed files with 3 additions and 2 deletions

View File

@ -585,8 +585,9 @@ filter_trackers( tr_tracker_info * input, int input_count, int * setme_count )
* (note: this can leave gaps in the `tier' values, but since the calling
* function doesn't care, there's no point in removing the gaps...) */
for( i=0, in=n; i<in; ++i )
for( j=0, jn=n; j<jn; ++j )
if( (i!=j) && (tmp[i].port==tmp[j].port)
for( j=i+1, jn=n; j<jn; ++j )
if( (tmp[i].info.tier!=tmp[j].info.tier)
&& (tmp[i].port==tmp[j].port)
&& !tr_strcmp0(tmp[i].host,tmp[j].host)
&& !tr_strcmp0(tmp[i].path,tmp[j].path) )
tmp[j].info.tier = tmp[i].info.tier;