pakfire: Prevent an infinite loop with empty server list.

This commit is contained in:
Michael Tremer
2013-12-28 17:06:38 +01:00
parent aa29e9e46c
commit d58c41f1ef

View File

@@ -305,7 +305,12 @@ sub selectmirror {
}
}
logger("MIRROR INFO: $scount servers found in list");
if ($scount eq 0) {
logger("MIRROR INFO: Could not find any servers. Falling back to main server $Conf::mainserver");
return ("HTTP", $Conf::mainserver, "/$Conf::version");
}
### Choose a random server and test if it is online
# If the check fails try a new server.
# This will never give up.