So far, there are no flags to implement, so just call the
corresponding function with 0 passed as @flags.
Signed-off-by: Michal Privoznik <mprivozn(a)redhat.com>
---
src/vmware/vmware_driver.c | 24 ++++++++++++++++++++++--
1 file changed, 22 insertions(+), 2 deletions(-)
diff --git a/src/vmware/vmware_driver.c b/src/vmware/vmware_driver.c
index 0e7a37f..ba1b8ed 100644
--- a/src/vmware/vmware_driver.c
+++ b/src/vmware/vmware_driver.c
@@ -472,7 +472,8 @@ vmwareDomainDestroyFlags(virDomainPtr dom,
}
static int
-vmwareDomainSuspend(virDomainPtr dom)
+vmwareDomainSuspendFlags(virDomainPtr dom,
+ unsigned int flags)
{
struct vmware_driver *driver = dom->conn->privateData;
@@ -483,6 +484,8 @@ vmwareDomainSuspend(virDomainPtr dom)
};
int ret = -1;
+ virCheckFlags(0, -1);
+
if (driver->type == VMWARE_DRIVER_PLAYER) {
virReportError(VIR_ERR_INTERNAL_ERROR, "%s",
_("vmplayer does not support libvirt suspend/resume"
@@ -521,7 +524,14 @@ vmwareDomainSuspend(virDomainPtr dom)
}
static int
-vmwareDomainResume(virDomainPtr dom)
+vmwareDomainSuspend(virDomainPtr dom)
+{
+ return vmwareDomainSuspendFlags(dom, 0);
+}
+
+static int
+vmwareDomainResumeFlags(virDomainPtr dom,
+ unsigned int flags)
{
struct vmware_driver *driver = dom->conn->privateData;
@@ -532,6 +542,8 @@ vmwareDomainResume(virDomainPtr dom)
};
int ret = -1;
+ virCheckFlags(0, -1);
+
if (driver->type == VMWARE_DRIVER_PLAYER) {
virReportError(VIR_ERR_INTERNAL_ERROR, "%s",
_("vmplayer does not support libvirt suspend/resume "
@@ -570,6 +582,12 @@ vmwareDomainResume(virDomainPtr dom)
}
static int
+vmwareDomainResume(virDomainPtr dom)
+{
+ return vmwareDomainResumeFlags(dom, 0);
+}
+
+static int
vmwareDomainReboot(virDomainPtr dom, unsigned int flags)
{
struct vmware_driver *driver = dom->conn->privateData;
@@ -1175,7 +1193,9 @@ static virDriver vmwareDriver = {
.domainLookupByUUID = vmwareDomainLookupByUUID, /* 0.8.7 */
.domainLookupByName = vmwareDomainLookupByName, /* 0.8.7 */
.domainSuspend = vmwareDomainSuspend, /* 0.8.7 */
+ .domainSuspendFlags = vmwareDomainSuspendFlags, /* 1.2.2 */
.domainResume = vmwareDomainResume, /* 0.8.7 */
+ .domainResumeFlags = vmwareDomainResumeFlags, /* 1.2.2 */
.domainShutdown = vmwareDomainShutdown, /* 0.8.7 */
.domainShutdownFlags = vmwareDomainShutdownFlags, /* 0.9.10 */
.domainReboot = vmwareDomainReboot, /* 0.8.7 */
--
1.8.5.2