Merge tag 'block-5.16-2021-12-19' of git://git.kernel.dk/linux-block
[linux-2.6-microblaze.git] / net / vmw_vsock / af_vsock.c
index 7d851eb..ed0df83 100644 (file)
@@ -1322,6 +1322,8 @@ static int vsock_connect(struct socket *sock, struct sockaddr *addr,
                 * non-blocking call.
                 */
                err = -EALREADY;
+               if (flags & O_NONBLOCK)
+                       goto out;
                break;
        default:
                if ((sk->sk_state == TCP_LISTEN) ||