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

[libvirt] [PATCH 11/13] destroy: Implement internal API for vmware driver



---
 src/vmware/vmware_driver.c |   12 +++++++++++-
 1 files changed, 11 insertions(+), 1 deletions(-)

diff --git a/src/vmware/vmware_driver.c b/src/vmware/vmware_driver.c
index 7cec310..64de663 100644
--- a/src/vmware/vmware_driver.c
+++ b/src/vmware/vmware_driver.c
@@ -312,12 +312,15 @@ vmwareDomainDefineXML(virConnectPtr conn, const char *xml)
 }
 
 static int
-vmwareDomainShutdown(virDomainPtr dom)
+vmwareDomainShutdownWithFlags(virDomainPtr dom,
+                              unsigned int flags)
 {
     struct vmware_driver *driver = dom->conn->privateData;
     virDomainObjPtr vm;
     int ret = -1;
 
+    virCheckFlags(0, -1);
+
     vmwareDriverLock(driver);
 
     vm = virDomainFindByUUID(&driver->domains, dom->uuid);
@@ -351,6 +354,12 @@ vmwareDomainShutdown(virDomainPtr dom)
 }
 
 static int
+vmwareDomainShutdown(virDomainPtr dom)
+{
+    return vmwareDomainShutdownWithFlags(dom, 0);
+}
+
+static int
 vmwareDomainSuspend(virDomainPtr dom)
 {
     struct vmware_driver *driver = dom->conn->privateData;
@@ -968,6 +977,7 @@ static virDriver vmwareDriver = {
     .domainShutdown = vmwareDomainShutdown, /* 0.8.7 */
     .domainReboot = vmwareDomainReboot, /* 0.8.7 */
     .domainDestroy = vmwareDomainShutdown, /* 0.8.7 */
+    .domainDestroyWithFlags = vmwareDomainShutdownWithFlags, /* 0.9.4 */
     .domainGetOSType = vmwareGetOSType, /* 0.8.7 */
     .domainGetInfo = vmwareDomainGetInfo, /* 0.8.7 */
     .domainGetState = vmwareDomainGetState, /* 0.9.2 */
-- 
1.7.5.rc3


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