/**
* collectd - src/sensors.c
* Copyright (C) 2005-2008 Florian octo Forster
+ * Copyright (C) 2006 Luboš Staněk
*
* This program is free software; you can redistribute it and/or modify it
* under the terms of the GNU General Public License as published by the
}
else if (chip->bus == SENSORS_CHIP_NAME_BUS_DUMMY)
{
- ssnprintf (buf, buf_size, "%s-%s-%04x",
+ status = snprintf (buf, buf_size, "%s-%s-%04x",
chip->prefix,
chip->busname,
chip->addr);
}
else
{
- ssnprintf (buf, buf_size, "%s-i2c-%d-%02x",
+ status = snprintf (buf, buf_size, "%s-i2c-%d-%02x",
chip->prefix,
chip->bus,
chip->addr);
else if (strcasecmp (key, "IgnoreSelected") == 0)
{
ignorelist_set_invert (sensor_list, 1);
- if ((strcasecmp (value, "True") == 0)
- || (strcasecmp (value, "Yes") == 0)
- || (strcasecmp (value, "On") == 0))
+ if (IS_TRUE (value))
ignorelist_set_invert (sensor_list, 0);
}
else
vl.values = values;
vl.values_len = 1;
- vl.time = time (NULL);
sstrncpy (vl.host, hostname_g, sizeof (vl.host));
sstrncpy (vl.plugin, "sensors", sizeof (vl.plugin));