summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 055c714)
raw | patch | inline | side by side (parent: 055c714)
author | Johan Wirén <johan.wiren.se@gmail.com> | |
Mon, 18 Mar 2013 21:49:32 +0000 (22:49 +0100) | ||
committer | Johan Wirén <johan.wiren.se@gmail.com> | |
Mon, 18 Mar 2013 21:49:32 +0000 (22:49 +0100) |
src/libvirt.c | patch | blob | history |
diff --git a/src/libvirt.c b/src/libvirt.c
index 6b0cf9a43920f2a1300ce1340198f4b06130e51d..10ca37f7e92dcb57b04f207a84d2f43e3c0f438e 100644 (file)
--- a/src/libvirt.c
+++ b/src/libvirt.c
} /* void init_value_list */
static void
-memory_submit (unsigned long memory, virDomainPtr dom, const char *type)
+memory_submit (gauge_t memory, virDomainPtr dom)
{
value_t values[1];
value_list_t vl = VALUE_LIST_INIT;
vl.values = values;
vl.values_len = 1;
- sstrncpy (vl.type, type, sizeof (vl.type));
+ sstrncpy (vl.type, "memory", sizeof (vl.type));
plugin_dispatch_values (&vl);
}
}
cpu_submit (info.cpuTime, domains[i], "virt_cpu_total");
- memory_submit (info.memory, domains[i], "memory");
+ memory_submit ((gauge_t) info.memory, domains[i]);
vinfo = malloc (info.nrVirtCpu * sizeof (vinfo[0]));
if (vinfo == NULL) {