[libvirt] [PATCH] Initialize vm def monitor fd

Jim Meyering jim at meyering.net
Tue Feb 17 09:35:17 UTC 2009


Cole Robinson <crobinso at redhat.com> wrote:

> We weren't properly initializing the monitor fd value in the VM
> definition structure. If qemu failed to start up, this could lead to
> closing stdin, which made all sorts of poo hit the fan. The attached
> patch fixes this.
>
> Thanks,
> Cole
>
> diff --git a/src/domain_conf.c b/src/domain_conf.c
> index e46bf43..622665c 100644
> --- a/src/domain_conf.c
> +++ b/src/domain_conf.c
> @@ -504,6 +504,7 @@ virDomainObjPtr virDomainAssignDef(virConnectPtr conn,
>      domain->state = VIR_DOMAIN_SHUTOFF;
>      domain->def = def;
>      domain->monitor_watch = -1;
> +    domain->monitor = -1;

BTW, this is part of Daniel Berrange's
"Fix multiple bugs in RPC handling" patch,
so I already have a reproducer for it.




More information about the libvir-list mailing list