X-Git-Url: https://git.octo.it/?p=collectd.git;a=blobdiff_plain;f=src%2Fipmi.c;h=98cc3b057eb6c043ba7cbc7e92d671d7e7f4de35;hp=6a72b2b7ccd8d0a88cc35c840e7cf90f2a6b76ec;hb=0d9f395599348e735e6f461e1c328293bef0d060;hpb=063088e8cef664a980f8d8469606ab7fd8f36b5b diff --git a/src/ipmi.c b/src/ipmi.c index 6a72b2b7..98cc3b05 100644 --- a/src/ipmi.c +++ b/src/ipmi.c @@ -1062,9 +1062,14 @@ static int c_ipmi_config_add_instance(oconfig_item_t *ci) { for (int i = 0; i < ci->children_num; i++) { oconfig_item_t *child = ci->children + i; - if (strcasecmp("Sensor", child->key) == 0) - ignorelist_add(st->ignorelist, child->values[0].value.string); - else if (strcasecmp("IgnoreSelected", child->key) == 0) { + if (strcasecmp("Sensor", child->key) == 0) { + char *value = NULL; + status = cf_util_get_string(child, &value); + if (status != 0) + break; + ignorelist_add(st->ignorelist, value); + sfree(value); + } else if (strcasecmp("IgnoreSelected", child->key) == 0) { _Bool t; status = cf_util_get_boolean(child, &t); if (status != 0)