vt.gauge = value;
vl.values = &vt;
+ vl.values_len = 1;
+
+ sstrncpy (vl.host, hostname_g, sizeof (vl.host));
sstrncpy (vl.plugin, "thermal", sizeof(vl.plugin));
sstrncpy (vl.plugin_instance, plugin_instance,
sizeof(vl.plugin_instance));
else if (strcasecmp (key, "IgnoreSelected") == 0)
{
ignorelist_set_invert (device_list, 1);
- if ((strcasecmp (value, "True") == 0)
- || (strcasecmp (value, "Yes") == 0)
- || (strcasecmp (value, "On") == 0))
+ if (IS_TRUE (value))
ignorelist_set_invert (device_list, 0);
}
else if (strcasecmp (key, "ForceUseProcfs") == 0)
{
force_procfs = 0;
- if ((strcasecmp (value, "True") == 0)
- || (strcasecmp (value, "Yes") == 0)
- || (strcasecmp (value, "On") == 0))
+ if (IS_TRUE (value))
force_procfs = 1;
}
else
static int thermal_sysfs_read (void)
{
return walk_directory (dirname_sysfs, thermal_sysfs_device_read,
- /* user_data = */ NULL);
+ /* user_data = */ NULL, /* include hidden */ 0);
}
static int thermal_procfs_read (void)
{
return walk_directory (dirname_procfs, thermal_procfs_device_read,
- /* user_data = */ NULL);
+ /* user_data = */ NULL, /* include hidden */ 0);
}
static int thermal_init (void)