summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--debian/changelog4
-rw-r--r--methods/connect.cc4
2 files changed, 6 insertions, 2 deletions
diff --git a/debian/changelog b/debian/changelog
index 558b657ce..840fd697c 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -12,6 +12,10 @@ apt (0.9.7.9~exp2) UNRELEASED; urgency=low
- fix test now that #1098752 is fixed
* po/{ca,cs,ru}.po:
- fix merge artifact
+
+ [ Michael Vogt ]
+ * methods/connect.cc:
+ - use Errno() instead of strerror(), thanks to David Kalnischk
-- Christian Perrier <bubulle@debian.org> Sun, 24 Mar 2013 08:57:45 +0100
diff --git a/methods/connect.cc b/methods/connect.cc
index 35f4723ce..fc7a72ee9 100644
--- a/methods/connect.cc
+++ b/methods/connect.cc
@@ -206,8 +206,8 @@ bool Connect(std::string Host,int Port,const char *Service,int DefPort,int &Fd,
Host.c_str());
}
if (Res == EAI_SYSTEM)
- return _error->Error(_("System error resolving '%s:%s' (%s)"),
- Host.c_str(),ServStr,strerror(errno));
+ return _error->Errno("getaddrinfo", _("System error resolving '%s:%s'"),
+ Host.c_str(),ServStr);
return _error->Error(_("Something wicked happened resolving '%s:%s' (%i - %s)"),
Host.c_str(),ServStr,Res,gai_strerror(Res));
}