X-Git-Url: https://git.octo.it/?a=blobdiff_plain;f=src%2Ftarget_v5upgrade.c;h=650f9a5eae769ebb8e62afeaa4b2c5a169436b94;hb=b9b5e5d573d0011c4f3276e9b84b73ba4dd2e870;hp=90f8e005883cf42d467e1326545116a23ed8962b;hpb=307c875e5a78a2729fbbe1a588d232e9a129d75a;p=collectd.git diff --git a/src/target_v5upgrade.c b/src/target_v5upgrade.c index 90f8e005..650f9a5e 100644 --- a/src/target_v5upgrade.c +++ b/src/target_v5upgrade.c @@ -213,15 +213,15 @@ static int v5_mysql_threads(const data_set_t *ds, value_list_t *vl) /* {{{ */ static int v5_zfs_arc_counts(const data_set_t *ds, value_list_t *vl) /* {{{ */ { value_list_t new_vl; - _Bool is_hits; + bool is_hits; if (vl->values_len != 4) return FC_TARGET_STOP; if (strcmp("hits", vl->type_instance) == 0) - is_hits = 1; + is_hits = true; else if (strcmp("misses", vl->type_instance) == 0) - is_hits = 0; + is_hits = false; else return FC_TARGET_STOP; @@ -238,23 +238,23 @@ static int v5_zfs_arc_counts(const data_set_t *ds, value_list_t *vl) /* {{{ */ /* Dispatch new value lists instead of this one */ new_vl.values[0].derive = (derive_t)vl->values[0].counter; - ssnprintf(new_vl.type_instance, sizeof(new_vl.type_instance), - "demand_data-%s", is_hits ? "hit" : "miss"); + snprintf(new_vl.type_instance, sizeof(new_vl.type_instance), "demand_data-%s", + is_hits ? "hit" : "miss"); plugin_dispatch_values(&new_vl); new_vl.values[0].derive = (derive_t)vl->values[1].counter; - ssnprintf(new_vl.type_instance, sizeof(new_vl.type_instance), - "demand_metadata-%s", is_hits ? "hit" : "miss"); + snprintf(new_vl.type_instance, sizeof(new_vl.type_instance), + "demand_metadata-%s", is_hits ? "hit" : "miss"); plugin_dispatch_values(&new_vl); new_vl.values[0].derive = (derive_t)vl->values[2].counter; - ssnprintf(new_vl.type_instance, sizeof(new_vl.type_instance), - "prefetch_data-%s", is_hits ? "hit" : "miss"); + snprintf(new_vl.type_instance, sizeof(new_vl.type_instance), + "prefetch_data-%s", is_hits ? "hit" : "miss"); plugin_dispatch_values(&new_vl); new_vl.values[0].derive = (derive_t)vl->values[3].counter; - ssnprintf(new_vl.type_instance, sizeof(new_vl.type_instance), - "prefetch_metadata-%s", is_hits ? "hit" : "miss"); + snprintf(new_vl.type_instance, sizeof(new_vl.type_instance), + "prefetch_metadata-%s", is_hits ? "hit" : "miss"); plugin_dispatch_values(&new_vl); /* Abort processing */