aboutsummaryrefslogtreecommitdiffstats
path: root/net/tipc/socket.c
diff options
context:
space:
mode:
Diffstat (limited to 'net/tipc/socket.c')
-rw-r--r--net/tipc/socket.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/net/tipc/socket.c b/net/tipc/socket.c
index 844bf349bb81..83f466e57fea 100644
--- a/net/tipc/socket.c
+++ b/net/tipc/socket.c
@@ -1507,14 +1507,12 @@ static int connect(struct socket *sock, struct sockaddr *dest, int destlen,
1507 sock->state != SS_CONNECTING, 1507 sock->state != SS_CONNECTING,
1508 timeout ? (long)msecs_to_jiffies(timeout) 1508 timeout ? (long)msecs_to_jiffies(timeout)
1509 : MAX_SCHEDULE_TIMEOUT); 1509 : MAX_SCHEDULE_TIMEOUT);
1510 lock_sock(sk);
1511 if (res <= 0) { 1510 if (res <= 0) {
1512 if (res == 0) 1511 if (res == 0)
1513 res = -ETIMEDOUT; 1512 res = -ETIMEDOUT;
1514 else 1513 return res;
1515 ; /* leave "res" unchanged */
1516 goto exit;
1517 } 1514 }
1515 lock_sock(sk);
1518 } 1516 }
1519 1517
1520 if (unlikely(sock->state == SS_DISCONNECTING)) 1518 if (unlikely(sock->state == SS_DISCONNECTING))