summaryrefslogtreecommitdiff
path: root/methods/connect.cc
diff options
context:
space:
mode:
authorMichael Vogt <mvo@debian.org>2014-01-28 16:43:49 +0100
committerMichael Vogt <mvo@debian.org>2014-01-28 16:43:49 +0100
commitacead5b93cf49ab33cba4be2ea8e1b253ed0f2bf (patch)
tree7c8631716d2182c7891533a0e4ce3b6962595f17 /methods/connect.cc
parentf4a631adf2f14c99d61ecb7f61cb1b3625c1cde4 (diff)
parentbae81c1307e956aa8928c9d6a77830fb733cd61f (diff)
Merge branch 'debian/sid' into ubuntu/master
Diffstat (limited to 'methods/connect.cc')
-rw-r--r--methods/connect.cc6
1 files changed, 3 insertions, 3 deletions
diff --git a/methods/connect.cc b/methods/connect.cc
index fc7a72ee9..d9c9a1dd4 100644
--- a/methods/connect.cc
+++ b/methods/connect.cc
@@ -142,9 +142,9 @@ bool Connect(std::string Host,int Port,const char *Service,int DefPort,int &Fd,
// Convert the port name/number
char ServStr[300];
if (Port != 0)
- snprintf(ServStr,sizeof(ServStr),"%u",Port);
+ snprintf(ServStr,sizeof(ServStr),"%i", Port);
else
- snprintf(ServStr,sizeof(ServStr),"%s",Service);
+ snprintf(ServStr,sizeof(ServStr),"%s", Service);
/* We used a cached address record.. Yes this is against the spec but
the way we have setup our rotating dns suggests that this is more
@@ -190,7 +190,7 @@ bool Connect(std::string Host,int Port,const char *Service,int DefPort,int &Fd,
{
if (DefPort != 0)
{
- snprintf(ServStr,sizeof(ServStr),"%u",DefPort);
+ snprintf(ServStr, sizeof(ServStr), "%i", DefPort);
DefPort = 0;
continue;
}