summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPeter Lieven <pl@kamp.de>2013-07-11 14:16:24 +0200
committerMichael Roth <mdroth@linux.vnet.ibm.com>2013-08-12 19:14:35 -0500
commitff57f145c1a525183c45af4d21b395761e7b88a1 (patch)
tree216e4f5654ac129bd67c085f562f83295b576ca5
parente6f5128dcf6d116ae3c829fbc0bcafd91b38af81 (diff)
downloadqemu-ff57f145c1a525183c45af4d21b395761e7b88a1.tar.gz
iscsi: fix -ENOSPC in iscsi_create()
the -ENOPSC case did not work due to the missing goto. Reported-by: Kevin Wolf <kwolf@redhat.com> Signed-off-by: Peter Lieven <pl@kamp.de> Cc: qemu-stable@nongnu.org Signed-off-by: Paolo Bonzini <pbonzini@redhat.com> (cherry picked from commit d3bda7bc166f40326ba646ee145630bb1b59da96) Signed-off-by: Michael Roth <mdroth@linux.vnet.ibm.com>
-rw-r--r--block/iscsi.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/block/iscsi.c b/block/iscsi.c
index fa5252cc40..91b602c538 100644
--- a/block/iscsi.c
+++ b/block/iscsi.c
@@ -1272,6 +1272,7 @@ static int iscsi_create(const char *filename, QEMUOptionParameter *options)
}
if (bs.total_sectors < total_size) {
ret = -ENOSPC;
+ goto out;
}
ret = 0;