commit
4b53d0d4ac9c "libxl: don't remove persistent domain on start
failure" cleans up the vm object and sets it to NULL if the vm is not
persistent, however at end job vm (now NULL) is dereferenced via the call to
libxlDomainObjEndJob. Avoid this by skipping "endjob" and going
straight to "cleanup" in this case.
Signed-off-by: Ian Campbell <ian.campbell@citrix.com>
(cherry picked from commit
ee7758f09bad855f5d0fdf9804d8979cdbbff40e)
if (!vm->persistent) {
virDomainObjListRemove(driver->domains, vm);
vm = NULL;
+ goto cleanup;
}
goto endjob;
}