summaryrefslogtreecommitdiff
path: root/content/fetch.c
diff options
context:
space:
mode:
Diffstat (limited to 'content/fetch.c')
-rw-r--r--content/fetch.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/content/fetch.c b/content/fetch.c
index 23650c530..3508b78cf 100644
--- a/content/fetch.c
+++ b/content/fetch.c
@@ -415,6 +415,7 @@ void fetch_dispatch_jobs(void)
*/
bool fetch_choose_and_dispatch(void)
{
+ bool same_host;
struct fetch *queueitem;
queueitem = queue_ring;
do {
@@ -428,6 +429,15 @@ bool fetch_choose_and_dispatch(void)
/* We can dispatch this item in theory */
return fetch_dispatch_job(queueitem);
}
+ /* skip over other items with the same host */
+ same_host = true;
+ while (same_host == true && queueitem->r_next != queue_ring) {
+ if (lwc_string_isequal(queueitem->host,
+ queueitem->r_next->host, &same_host) ==
+ lwc_error_ok && same_host == true) {
+ queueitem = queueitem->r_next;
+ }
+ }
queueitem = queueitem->r_next;
} while (queueitem != queue_ring);
return false;