]> git.proxmox.com Git - qemu.git/commitdiff
iscsi: fix -ENOSPC in iscsi_create()
authorPeter Lieven <pl@kamp.de>
Thu, 11 Jul 2013 12:16:24 +0000 (14:16 +0200)
committerMichael Roth <mdroth@linux.vnet.ibm.com>
Tue, 13 Aug 2013 00:14:35 +0000 (19:14 -0500)
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>
block/iscsi.c

index fa5252cc40cc6ba4c93ee46d7abf8471af262548..91b602c53844738a6acc14ba1bf92472581680c4 100644 (file)
@@ -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;