aboutsummaryrefslogtreecommitdiff
path: root/block/nbd.c
diff options
context:
space:
mode:
authorStefan Hajnoczi <stefanha@redhat.com>2013-04-15 16:14:46 +0200
committerPaolo Bonzini <pbonzini@redhat.com>2013-04-15 16:29:46 +0200
commit6760c47aa42ce30efdd12c132f73c8749c575995 (patch)
treeeb199a30156c8c7f42e158a33d2c7e6bb56dca8f /block/nbd.c
parente2ec3f976803b360c70d9ae2ba13852fa5d11665 (diff)
nbd: unlock mutex in nbd_co_send_request() error path
Cc: qemu-stable@nongnu.org Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
Diffstat (limited to 'block/nbd.c')
-rw-r--r--block/nbd.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/block/nbd.c b/block/nbd.c
index eff683c8df..662df16415 100644
--- a/block/nbd.c
+++ b/block/nbd.c
@@ -339,7 +339,7 @@ static int nbd_co_send_request(BDRVNBDState *s, struct nbd_request *request,
ret = qemu_co_sendv(s->sock, qiov->iov, qiov->niov,
offset, request->len);
if (ret != request->len) {
- return -EIO;
+ rc = -EIO;
}
}
qemu_aio_set_fd_handler(s->sock, nbd_reply_ready, NULL,