summaryrefslogtreecommitdiffstats
path: root/nbd.c
diff options
context:
space:
mode:
Diffstat (limited to 'nbd.c')
-rw-r--r--nbd.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/nbd.c b/nbd.c
index fc34c44..b3d9654 100644
--- a/nbd.c
+++ b/nbd.c
@@ -1446,6 +1446,7 @@ static void nbd_set_handlers(NBDClient *client)
{
if (client->exp && client->exp->ctx) {
aio_set_fd_handler(client->exp->ctx, client->sock,
+ true,
client->can_read ? nbd_read : NULL,
client->send_coroutine ? nbd_restart_write : NULL,
client);
@@ -1455,7 +1456,8 @@ static void nbd_set_handlers(NBDClient *client)
static void nbd_unset_handlers(NBDClient *client)
{
if (client->exp && client->exp->ctx) {
- aio_set_fd_handler(client->exp->ctx, client->sock, NULL, NULL, NULL);
+ aio_set_fd_handler(client->exp->ctx, client->sock,
+ true, NULL, NULL, NULL);
}
}
OpenPOWER on IntegriCloud