summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorWayne Davison <wayned@samba.org>2011-08-06 11:21:40 -0700
committerWayne Davison <wayned@samba.org>2011-08-06 11:23:09 -0700
commitfe2c165fca8bd5e9fa9660378647841e6b5a08d4 (patch)
tree499c026d437c1fdc2e56086c66022eeeeaa6c761
parent4c0055ecbb51f7fbc878229ec615f93e1adc506f (diff)
downloadrsync-fe2c165fca8bd5e9fa9660378647841e6b5a08d4.tar.gz
Fix misplaced parens on getnameinfo() call.
-rw-r--r--socket.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/socket.c b/socket.c
index c373056f..b0d54750 100644
--- a/socket.c
+++ b/socket.c
@@ -303,7 +303,7 @@ int open_socket_out(char *host, int port, const char *bind_addr,
}
if (verbose >= 3) {
char buf[2048];
- if ((error = getnameinfo(res->ai_addr, res->ai_addrlen, buf, sizeof buf, NULL, 0, NI_NUMERICHOST) != 0))
+ if ((error = getnameinfo(res->ai_addr, res->ai_addrlen, buf, sizeof buf, NULL, 0, NI_NUMERICHOST)) != 0)
snprintf(buf, sizeof buf, "*getnameinfo failure: %s*", gai_strerror(error));
rprintf(FINFO, "Connected to %s (%s)\n", h, buf);
}
@@ -315,7 +315,7 @@ int open_socket_out(char *host, int port, const char *bind_addr,
for (res = res0, j = 0; res; res = res->ai_next, j++) {
if (errnos[j] == 0)
continue;
- if ((error = getnameinfo(res->ai_addr, res->ai_addrlen, buf, sizeof buf, NULL, 0, NI_NUMERICHOST) != 0))
+ if ((error = getnameinfo(res->ai_addr, res->ai_addrlen, buf, sizeof buf, NULL, 0, NI_NUMERICHOST)) != 0)
snprintf(buf, sizeof buf, "*getnameinfo failure: %s*", gai_strerror(error));
rsyserr(FERROR, errnos[j], "failed to connect to %s (%s)", h, buf);
}