]> git.ipfire.org Git - thirdparty/rsync.git/commitdiff
Fix misplaced parens on getnameinfo() call.
authorWayne Davison <wayned@samba.org>
Sat, 6 Aug 2011 18:21:40 +0000 (11:21 -0700)
committerWayne Davison <wayned@samba.org>
Sat, 6 Aug 2011 18:21:40 +0000 (11:21 -0700)
socket.c

index 0f596e0dfb38024bba59f59beeba526031cad602..84f9b0c2c6d1244f92cd2d2c1c018d528b6286c0 100644 (file)
--- a/socket.c
+++ b/socket.c
@@ -303,7 +303,7 @@ int open_socket_out(char *host, int port, const char *bind_addr,
                }
                if (DEBUG_GTE(CONNECT, 2)) {
                        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);
                }