From: Florian Forster Date: Mon, 10 Sep 2012 19:10:45 +0000 (+0200) Subject: Merge branch 'ff/kstat' into collectd-4.10 X-Git-Tag: collectd-5.0.5~4^2~18 X-Git-Url: https://git.octo.it/?a=commitdiff_plain;h=dd5fc7ca70168375863161967d6738914ea008b7;hp=a4872adedee43b05feaee42e13007b0fe0afc41c;p=collectd.git Merge branch 'ff/kstat' into collectd-4.10 --- diff --git a/src/df.c b/src/df.c index 22264d30..dc7be1eb 100644 --- a/src/df.c +++ b/src/df.c @@ -257,6 +257,8 @@ static int df_read (void) { if (strcmp (mnt_ptr->dir, "/") == 0) { + if (strcmp (mnt_ptr->type, "rootfs") == 0) + continue; sstrncpy (disk_name, "root", sizeof (disk_name)); } else diff --git a/src/snmp.c b/src/snmp.c index 5c6cce26..2b0b463f 100644 --- a/src/snmp.c +++ b/src/snmp.c @@ -302,7 +302,7 @@ static int csnmp_config_add_data_shift (data_definition_t *dd, oconfig_item_t *c if ((ci->values_num != 1) || (ci->values[0].type != OCONFIG_TYPE_NUMBER)) { - WARNING ("snmp plugin: The `Scale' config option needs exactly one number argument."); + WARNING ("snmp plugin: The `Shift' config option needs exactly one number argument."); return (-1); } @@ -886,10 +886,12 @@ static int csnmp_check_res_left_subtree (const host_definition_t *host, vb = vb->next_variable, i++) { num_checked++; - if (snmp_oid_ncompare (data->values[i].oid, - data->values[i].oid_len, - vb->name, vb->name_length, - data->values[i].oid_len) != 0) + + if ((vb->type == SNMP_ENDOFMIBVIEW) + || (snmp_oid_ncompare (data->values[i].oid, + data->values[i].oid_len, + vb->name, vb->name_length, + data->values[i].oid_len) != 0)) num_left_subtree++; }