diff --git a/net/tipc/topsrv.c b/net/tipc/topsrv.c index 3a12fc18239b8184526b027ee9b3afce5893f717..73dbed0c4b6b8dd5fa4ee484208349b9f7a85455 100644 --- a/net/tipc/topsrv.c +++ b/net/tipc/topsrv.c @@ -402,10 +402,11 @@ static int tipc_conn_rcv_from_sock(struct tipc_conn *con) read_lock_bh(&sk->sk_callback_lock); ret = tipc_conn_rcv_sub(srv, con, &s); read_unlock_bh(&sk->sk_callback_lock); + if (!ret) + return 0; } - if (ret < 0) - tipc_conn_close(con); + tipc_conn_close(con); return ret; }