Instead of giving up if a login attempt fails, try all network interfaces.
This patch ensures that login succeeds if the first network interface that
is encountered is down and another network interface is up.
Signed-off-by: Bart Van Assche <bvanassche@acm.org>