Merge branch 'collectd-5.4'
[collectd.git] / src / memory.c
index b1f2e76..c503821 100644 (file)
@@ -18,7 +18,7 @@
  * 51 Franklin St, Fifth Floor, Boston, MA  02110-1301 USA
  *
  * Authors:
- *   Florian octo Forster <octo at verplant.org>
+ *   Florian octo Forster <octo at collectd.org>
  *   Simon Kuhnle <simon at blarzwurst.de>
  *   Manuel Sanmartin
  **/
@@ -212,7 +212,7 @@ static int memory_read_internal (value_list_t *vl)
        free     = (gauge_t) (((uint64_t) vm_data.free_count)     * ((uint64_t) pagesize));
 
        MEMORY_SUBMIT ("wired",    wired,
-                       "active",   active,
+                      "active",   active,
                       "inactive", inactive,
                       "free",     free);
 /* #endif HAVE_HOST_STATISTICS */
@@ -332,14 +332,13 @@ static int memory_read_internal (value_list_t *vl)
 /* #endif KERNEL_LINUX */
 
 #elif HAVE_LIBKSTAT
-        /* Most of the additions here were taken as-is from the k9toolkit from
-         * Brendan Gregg and are subject to change I guess */
+       /* Most of the additions here were taken as-is from the k9toolkit from
+        * Brendan Gregg and are subject to change I guess */
        long long mem_used;
        long long mem_free;
        long long mem_lock;
        long long mem_kern;
        long long mem_unus;
-       long long mem_total;
 
        long long pp_kernel;
        long long physmem;
@@ -488,6 +487,7 @@ static int memory_read (void) /* {{{ */
        vl.values_len = STATIC_ARRAY_SIZE (v);
        sstrncpy (vl.host, hostname_g, sizeof (vl.host));
        sstrncpy (vl.plugin, "memory", sizeof (vl.plugin));
+       sstrncpy (vl.type, "memory", sizeof (vl.type));
        vl.time = cdtime ();
 
        return (memory_read_internal (&vl));