
On 07/19/2011 09:57 AM, Osier Yang wrote:
--- src/esx/esx_driver.c | 11 ++++++++++- src/lxc/lxc_driver.c | 11 ++++++++++- src/openvz/openvz_driver.c | 11 ++++++++++- src/test/test_driver.c | 12 +++++++++++- src/uml/uml_driver.c | 12 +++++++++++- src/vmware/vmware_driver.c | 12 +++++++++++- src/xen/xen_driver.c | 9 ++++++++- 7 files changed, 71 insertions(+), 7 deletions(-)
+++ b/src/test/test_driver.c @@ -2535,12 +2535,16 @@ static int testDomainCreate(virDomainPtr domain) { return testDomainCreateWithFlags(domain, 0); }
-static int testDomainUndefine(virDomainPtr domain) { +static int testDomainUndefineFlags(virDomainPtr domain, + unsigned int flags) +{ testConnPtr privconn = domain->conn->privateData; virDomainObjPtr privdom; virDomainEventPtr event = NULL; int ret = -1;
+ virCheckFlags(0, -1);
Huh, I just realized: Since these hypervisors do not support managed save in the first place, we could argue that they trivially support VIR_DOMAIN_UNDEFINE_MANAGED_SAVE (that is, they properly guarantee that all managed save files are safely deleted, since none exist in the first place). We could change all of these virCheckFlags(0, -1) into virCheckFlags(VIR_DOMAIN_UNDEFINE_MANAGED_SAVE, -1), so that 'virsh undefine dom --managed-save' would also work on these hypervisors. I'm not sure whether to make that change though, so let's push this patch as-is, and debate about that change as a separate item. ACK. -- Eric Blake eblake@redhat.com +1-801-349-2682 Libvirt virtualization library http://libvirt.org