[libvirt] [PATCH 1/4] qemu: Properly cleanup in security startup error path

Eric Blake eblake at redhat.com
Tue May 18 15:29:08 UTC 2010


On 05/17/2010 11:17 AM, Cole Robinson wrote:
> Everything after hostdev setup needs to jump to cleanup on error.
> 
> Signed-off-by: Cole Robinson <crobinso at redhat.com>
> ---
>  src/qemu/qemu_driver.c |    2 +-
>  1 files changed, 1 insertions(+), 1 deletions(-)
> 
> diff --git a/src/qemu/qemu_driver.c b/src/qemu/qemu_driver.c
> index 582fdee..80f96b7 100644
> --- a/src/qemu/qemu_driver.c
> +++ b/src/qemu/qemu_driver.c
> @@ -3295,7 +3295,7 @@ static int qemudStartVMDaemon(virConnectPtr conn,
>      if (driver->securityDriver &&
>          driver->securityDriver->domainGenSecurityLabel &&
>          driver->securityDriver->domainGenSecurityLabel(vm) < 0)
> -        return -1;
> +        goto cleanup;

ACK.

-- 
Eric Blake   eblake at redhat.com    +1-801-349-2682
Libvirt virtualization library http://libvirt.org

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 619 bytes
Desc: OpenPGP digital signature
URL: <http://listman.redhat.com/archives/libvir-list/attachments/20100518/7dbe3a77/attachment-0001.sig>


More information about the libvir-list mailing list