Blob Blame History Raw
From 86426efffd910c22c9cfadc50516883b606c6946 Mon Sep 17 00:00:00 2001
Message-Id: <86426efffd910c22c9cfadc50516883b606c6946@dist-git>
From: Pavel Hrdina <phrdina@redhat.com>
Date: Mon, 1 Jul 2019 17:06:03 +0200
Subject: [PATCH] vircgroup: fix MinGW build
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

Broken by commit <901d2b9c87>.

Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
(cherry picked from commit baebd9f3d84b5cb86c7c6f35eb41cf9fb7e9b624)

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

Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
Message-Id: <bb4185916d7e3937b58f9019feb5abf3ba6e4823.1561993099.git.phrdina@redhat.com>
Reviewed-by: Ján Tomko <jtomko@redhat.com>
---
 src/util/vircgroup.c | 15 +++++++++++++++
 1 file changed, 15 insertions(+)

diff --git a/src/util/vircgroup.c b/src/util/vircgroup.c
index 0ed83932ac..df38bb77e0 100644
--- a/src/util/vircgroup.c
+++ b/src/util/vircgroup.c
@@ -4335,6 +4335,21 @@ virCgroupSetMemory(virCgroupPtr group ATTRIBUTE_UNUSED,
 }
 
 
+int
+virCgroupGetMemoryStat(virCgroupPtr group ATTRIBUTE_UNUSED,
+                       unsigned long long *cache ATTRIBUTE_UNUSED,
+                       unsigned long long *activeAnon ATTRIBUTE_UNUSED,
+                       unsigned long long *inactiveAnon ATTRIBUTE_UNUSED,
+                       unsigned long long *activeFile ATTRIBUTE_UNUSED,
+                       unsigned long long *inactiveFile ATTRIBUTE_UNUSED,
+                       unsigned long long *unevictable ATTRIBUTE_UNUSED)
+{
+    virReportSystemError(ENOSYS, "%s",
+                         _("Control groups not supported on this platform"));
+    return -1;
+}
+
+
 int
 virCgroupGetMemoryUsage(virCgroupPtr group ATTRIBUTE_UNUSED,
                         unsigned long *kb ATTRIBUTE_UNUSED)
-- 
2.22.0