From: Florian Forster Date: Mon, 27 Aug 2012 08:12:11 +0000 (+0200) Subject: Merge branch 'sh/collectd-5.1' into collectd-5.1 X-Git-Tag: collectd-5.1.1~11 X-Git-Url: https://git.octo.it/?a=commitdiff_plain;h=180f2ba844e00bd0e73acc5b4445b48652e47dcd;hp=b736009816ddeb00a2ec4c7e3986f98522215afd;p=collectd.git Merge branch 'sh/collectd-5.1' into collectd-5.1 --- diff --git a/src/nfs.c b/src/nfs.c index 58f2e0d2..461e806f 100644 --- a/src/nfs.c +++ b/src/nfs.c @@ -332,10 +332,12 @@ static int nfs_read_kstat (kstat_t *ksp, int nfs_version, char *inst, kstat_read(kc, ksp, NULL); for (i = 0; i < proc_names_num; i++) - values[i].counter = (derive_t) get_kstat_value (ksp, proc_names[i]); + values[i].counter = (derive_t) get_kstat_value (ksp, + (char *)proc_names[i]); nfs_procedures_submit (plugin_instance, proc_names, values, proc_names_num); + return (0); } #endif diff --git a/src/zfs_arc.c b/src/zfs_arc.c index e77569f5..f4352ff4 100644 --- a/src/zfs_arc.c +++ b/src/zfs_arc.c @@ -60,7 +60,7 @@ static int za_read_derive (kstat_t *ksp, const char *kstat_value, long long tmp; value_t v; - tmp = get_kstat_value (ksp, kstat_value); + tmp = get_kstat_value (ksp, (char *)kstat_value); if (tmp == -1LL) { ERROR ("zfs_arc plugin: Reading kstat value \"%s\" failed.", kstat_value); @@ -69,6 +69,7 @@ static int za_read_derive (kstat_t *ksp, const char *kstat_value, v.derive = (derive_t) tmp; za_submit (type, type_instance, /* values = */ &v, /* values_num = */ 1); + return (0); } static int za_read_gauge (kstat_t *ksp, const char *kstat_value, @@ -77,7 +78,7 @@ static int za_read_gauge (kstat_t *ksp, const char *kstat_value, long long tmp; value_t v; - tmp = get_kstat_value (ksp, kstat_value); + tmp = get_kstat_value (ksp, (char *)kstat_value); if (tmp == -1LL) { ERROR ("zfs_arc plugin: Reading kstat value \"%s\" failed.", kstat_value); @@ -86,6 +87,7 @@ static int za_read_gauge (kstat_t *ksp, const char *kstat_value, v.gauge = (gauge_t) tmp; za_submit (type, type_instance, /* values = */ &v, /* values_num = */ 1); + return (0); } static void za_submit_ratio (const char* type_instance, gauge_t hits, gauge_t misses)