aboutsummaryrefslogtreecommitdiff
path: root/qemu-nbd.c
diff options
context:
space:
mode:
Diffstat (limited to 'qemu-nbd.c')
-rw-r--r--qemu-nbd.c10
1 files changed, 3 insertions, 7 deletions
diff --git a/qemu-nbd.c b/qemu-nbd.c
index a4cf847976..ede4a54d4e 100644
--- a/qemu-nbd.c
+++ b/qemu-nbd.c
@@ -333,13 +333,9 @@ static void nbd_accept(void *opaque)
return;
}
- if (nbd_client_new(exp, fd, nbd_client_closed)) {
- nb_fds++;
- nbd_update_server_fd_handler(server_fd);
- } else {
- shutdown(fd, 2);
- close(fd);
- }
+ nb_fds++;
+ nbd_update_server_fd_handler(server_fd);
+ nbd_client_new(exp, fd, nbd_client_closed);
}
static void nbd_update_server_fd_handler(int fd)