Merge branch 'collectd-4.4'
[collectd.git] / src / swap.c
index e91ebef..4f0a0ba 100644 (file)
@@ -126,9 +126,10 @@ static void swap_submit (const char *type_instance, double value)
        vl.time = time (NULL);
        strcpy (vl.host, hostname_g);
        strcpy (vl.plugin, "swap");
-       strncpy (vl.type_instance, type_instance, sizeof (vl.type_instance));
+       strcpy (vl.type, "swap");
+       sstrncpy (vl.type_instance, type_instance, sizeof (vl.type_instance));
 
-       plugin_dispatch_values ("swap", &vl);
+       plugin_dispatch_values (&vl);
 } /* void swap_submit */
 
 static int swap_read (void)