[libvirt] [PATCH] Don't skip over socket label cleanup

Eric Blake eblake at redhat.com
Wed Sep 26 15:50:36 UTC 2012


On 09/26/2012 08:49 AM, Daniel P. Berrange wrote:
> From: "Daniel P. Berrange" <berrange at redhat.com>
> 
> If QEMU quits immediately after we opened the monitor it  was

extra space before 'was'

> possible we would skip the clearing of the SELinux process
> socket context
> 
> Signed-off-by: Daniel P. Berrange <berrange at redhat.com>
> ---
>  src/qemu/qemu_process.c | 7 +++----
>  1 file changed, 3 insertions(+), 4 deletions(-)

ACK, after reading more context.

> 
> diff --git a/src/qemu/qemu_process.c b/src/qemu/qemu_process.c
> index 70b72af..ade64b7 100644
> --- a/src/qemu/qemu_process.c
> +++ b/src/qemu/qemu_process.c
> @@ -1242,12 +1242,11 @@ qemuConnectMonitor(struct qemud_driver *driver, virDomainObjPtr vm)
>      virDomainObjLock(vm);
>      priv->monStart = 0;
>  
> -    if (mon == NULL)
> +    if (mon == NULL) {
>          virObjectUnref(vm);
> -
> -    if (!virDomainObjIsActive(vm)) {
> +    } else if (!virDomainObjIsActive(vm)) {
>          qemuMonitorClose(mon);
> -        goto error;
> +        mon = NULL;
>      }
>      priv->mon = mon;
>  
> 

-- 
Eric Blake   eblake at redhat.com    +1-919-301-3266
Libvirt virtualization library http://libvirt.org

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


More information about the libvir-list mailing list