Author: poeml Date: 2009-02-24 09:20:49 -0700 (Tue, 24 Feb 2009) New Revision: 6555 Modified: trunk/tools/download-redirector-v2/mod_mirrorbrain/mod_mirrorbrain.c Log: mod_mirrorbrain: - implement the missing redirection exceptions mirrors marked AS-only or prefix-only. Modified: trunk/tools/download-redirector-v2/mod_mirrorbrain/mod_mirrorbrain.c =================================================================== --- trunk/tools/download-redirector-v2/mod_mirrorbrain/mod_mirrorbrain.c 2009-02-24 16:04:49 UTC (rev 6554) +++ trunk/tools/download-redirector-v2/mod_mirrorbrain/mod_mirrorbrain.c 2009-02-24 16:20:49 UTC (rev 6555) _at_@ -1238,12 +1238,15 @@ } /* same AS? */ - else if (strcmp(new->as, as) == 0) { + else if ((strcmp(new->as, as) == 0) + && (new->prefix_only != 1)) { *(void **)apr_array_push(mirrors_same_as) = new; } /* same country? */ - else if (strcasecmp(new->country_code, country_code) == 0) { + else if ((strcasecmp(new->country_code, country_code) == 0) + && (new->as_only != 1) + && (new->prefix_only != 1)) { *(void **)apr_array_push(mirrors_same_country) = new; } _at_@ -1267,14 +1270,19 @@ /* to be actually considered for this group, the mirror must be willing * to take redirects from foreign country */ else if ((strcasecmp(new->region, continent_code) == 0) - && (new->country_only != 1)) { + && (new->country_only != 1) + && (new->as_only != 1) + && (new->prefix_only != 1)) { *(void **)apr_array_push(mirrors_same_region) = new; } /* to be considered as "worldwide" mirror, it must be willing * to take redirects from foreign regions. * (N.B. region_only implies country_only) */ - else if ((new->region_only != 1) && (new->country_only != 1)) { + else if ((new->region_only != 1) + && (new->country_only != 1) + && (new->as_only != 1) + && (new->prefix_only != 1)) { *(void **)apr_array_push(mirrors_elsewhere) = new; } _______________________________________________ Opensuse-svn mailing list Opensuse-svn_at_forge.novell.com http://forge.novell.com/mailman/listinfo/opensuse-svn _______________________________________________ mirrorbrain-commits mailing list Note: To remove yourself from this list, send a mail with the content unsubscribe to the address mirrorbrain-commits-request_at_mirrorbrain.orgReceived on Tue Feb 24 2009 - 16:21:21 GMT
This archive was generated by hypermail 2.3.0 : Mon Feb 20 2012 - 23:47:04 GMT