]> git.tue.mpg.de Git - paraslash.git/commitdiff
net: Remove unnecessary condition in makesock_addrinfo().
authorAndre Noll <maan@systemlinux.org>
Sun, 8 Sep 2013 04:22:29 +0000 (04:22 +0000)
committerAndre Noll <maan@systemlinux.org>
Wed, 1 Jan 2014 17:40:15 +0000 (17:40 +0000)
This code is executed only if src != NULL, which implies dst == NULL.

net.c

diff --git a/net.c b/net.c
index d00895f50342a528f9e6008e886c766a8808820e..205041fdaec3881c4196d3d7bada084036fea3bf 100644 (file)
--- a/net.c
+++ b/net.c
@@ -460,8 +460,8 @@ static int makesock_addrinfo(unsigned l4type, bool passive, struct addrinfo *ai,
                                close(sockfd);
                                goto get_next_src;
                        }
-                       if (!dst) /* bind-only completed successfully */
-                               break;
+                       /* bind completed successfully */
+                       break;
                }
 
                if (dst && connect(sockfd, dst->ai_addr, dst->ai_addrlen) == 0)