summaryrefslogtreecommitdiff
path: root/methods/connect.cc
diff options
context:
space:
mode:
authorJulian Andres Klode <julian.klode@canonical.com>2018-05-24 14:16:30 +0200
committerJulian Andres Klode <julian.klode@canonical.com>2018-05-24 14:26:16 +0200
commit71b65b3563d223f6cd69261918ec06d10da48e6c (patch)
tree44e4b587f55769ce376823fd5908c20e9ae0d10d /methods/connect.cc
parentd66606cb6abbfbbeae2720bcae44833a98f31598 (diff)
Handle a missed case of timed out ip addresses
Correctly register timed out IP addresses from a timed out select() call as a bad address so we do not try it again. LP: #1766542
Diffstat (limited to 'methods/connect.cc')
-rw-r--r--methods/connect.cc1
1 files changed, 1 insertions, 0 deletions
diff --git a/methods/connect.cc b/methods/connect.cc
index d4e4303b3..e5d17a2f5 100644
--- a/methods/connect.cc
+++ b/methods/connect.cc
@@ -307,6 +307,7 @@ static ResultState WaitAndCheckErrors(std::list<Connection> &Conns, std::unique_
for (auto &Conn : Conns)
{
Conn.Owner->SetFailReason("Timeout");
+ bad_addr.insert(bad_addr.begin(), Conn.Name);
_error->Error(_("Could not connect to %s:%s (%s), "
"connection timed out"),
Conn.Host.c_str(), Conn.Service, Conn.Name);