render / rpms / libvirt

Forked from rpms/libvirt 9 months ago
Clone
Blob Blame History Raw
From f3366321b1911d327985ed16717a8589869d6fb3 Mon Sep 17 00:00:00 2001
Message-Id: <f3366321b1911d327985ed16717a8589869d6fb3@dist-git>
From: Michal Privoznik <mprivozn@redhat.com>
Date: Mon, 1 Jul 2019 17:08:05 +0200
Subject: [PATCH] virt-host-validate: Fix build on non-Linux
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

For non-Linux platforms we have
virHostValidateCGroupControllers() stub which only reports an
error. But we are not marking the ignored arguments the way we
should.

Signed-off-by: Michal Privoznik <mprivozn@redhat.com>
Reviewed-by: Pavel Hrdina <phrdina@redhat.com>
(cherry picked from commit 8524faf8c4007edfbc5363a018821139667a9e32)

Resolves: https://bugzilla.redhat.com/show_bug.cgi?id=1689297

Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
Message-Id: <34a0cf3fd56060036b473a82c9b2b39beba0d589.1561993100.git.phrdina@redhat.com>
Reviewed-by: Ján Tomko <jtomko@redhat.com>
---
 tools/virt-host-validate-common.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/tools/virt-host-validate-common.c b/tools/virt-host-validate-common.c
index 73165d673a..5dd1605daa 100644
--- a/tools/virt-host-validate-common.c
+++ b/tools/virt-host-validate-common.c
@@ -324,8 +324,8 @@ int virHostValidateCGroupControllers(const char *hvname,
     return ret;
 }
 #else /*  !__linux__ */
-int virHostValidateCGroupControllers(const char *hvname,
-                                     int controllers,
+int virHostValidateCGroupControllers(const char *hvname ATTRIBUTE_UNUSED,
+                                     int controllers ATTRIBUTE_UNUSED,
                                      virHostValidateLevel level)
 {
     virHostMsgFail(level, "%s", "This platform does not support cgroups");
-- 
2.22.0