From 73dd8a4f79ed2290d645f480ef0efade51aea403 Mon Sep 17 00:00:00 2001 From: Christian Hesse Date: Sun, 5 Oct 2014 21:19:25 +0200 Subject: try to guess the fastest server for db files as well --- pacredir.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/pacredir.c b/pacredir.c index cc8ae03..fbb09bd 100644 --- a/pacredir.c +++ b/pacredir.c @@ -444,7 +444,8 @@ static int ahc_echo(void * cls, if (request->http_code == MHD_HTTP_OK && /* for db files choose the most recent server */ - ((dbfile == 1 && request->last_modified > last_modified) || + ((dbfile == 1 && request->last_modified >= last_modified && + request->time_total < time_total) || /* for packages try to guess the fastest server */ (dbfile == 0 && request->time_total < time_total))) { if (url != NULL) -- cgit v1.2.3-54-g00ecf