[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

Re: [libvirt] [PATCH 2/2] test: Update inactive guest config on shutdown



On Wed, Nov 04, 2009 at 02:39:43PM -0500, Cole Robinson wrote:
> This matches the expected behavior of state drivers such as QEMU.
> 
> Signed-off-by: Cole Robinson <crobinso redhat com>
> ---
>  src/test/test_driver.c |    6 ++++++
>  1 files changed, 6 insertions(+), 0 deletions(-)
> 
> diff --git a/src/test/test_driver.c b/src/test/test_driver.c
> index 35299d5..343834c 100644
> --- a/src/test/test_driver.c
> +++ b/src/test/test_driver.c
> @@ -473,6 +473,12 @@ static void
>  testDomainShutdownState(virDomainPtr domain,
>                          virDomainObjPtr privdom)
>  {
> +    if (privdom->newDef) {
> +        virDomainDefFree(privdom->def);
> +        privdom->def = privdom->newDef;
> +        privdom->newDef = NULL;
> +    }
> +
>      privdom->state = VIR_DOMAIN_SHUTOFF;
>      privdom->def->id = -1;
>      domain->id = -1;

  ACK,

Daniel

-- 
Daniel Veillard      | libxml Gnome XML XSLT toolkit  http://xmlsoft.org/
daniel veillard com  | Rpmfind RPM search engine http://rpmfind.net/
http://veillard.com/ | virtualization library  http://libvirt.org/


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]