summaryrefslogtreecommitdiff
path: root/examples/mem.c
diff options
context:
space:
mode:
Diffstat (limited to 'examples/mem.c')
-rw-r--r--examples/mem.c21
1 files changed, 21 insertions, 0 deletions
diff --git a/examples/mem.c b/examples/mem.c
new file mode 100644
index 00000000..63fba3de
--- /dev/null
+++ b/examples/mem.c
@@ -0,0 +1,21 @@
+#include <glibtop.h>
+#include <glibtop/mem.h>
+
+#include <glib.h>
+#include <unistd.h>
+
+int main(int argc, char **argv)
+{
+ glibtop_mem buf;
+
+ glibtop_init();
+
+ g_print("%lx\n", glibtop_global_server->features);
+
+ glibtop_get_mem(&buf);
+
+ glibtop_close();
+
+ return 0;
+}
+