From: Peter Lieven Date: Thu, 11 Jul 2013 12:16:24 +0000 (+0200) Subject: iscsi: fix -ENOSPC in iscsi_create() X-Git-Tag: v1.5.3~31 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=ff57f145c1a525183c45af4d21b395761e7b88a1;p=thirdparty%2Fqemu.git iscsi: fix -ENOSPC in iscsi_create() the -ENOPSC case did not work due to the missing goto. Reported-by: Kevin Wolf Signed-off-by: Peter Lieven Cc: qemu-stable@nongnu.org Signed-off-by: Paolo Bonzini (cherry picked from commit d3bda7bc166f40326ba646ee145630bb1b59da96) Signed-off-by: Michael Roth --- diff --git a/block/iscsi.c b/block/iscsi.c index fa5252cc40c..91b602c5384 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;