X-Git-Url: https://git.octo.it/?a=blobdiff_plain;f=src%2Futils_rrdcreate.c;h=4ecec59dae1cdad9d3128b25f241920d888d6fce;hb=69395dbecda0e01df70b69a61f72d12a897037d9;hp=c4e9d8ba9bdeb30778fcba3cecd98b4a63335e25;hpb=37905c5a2370c8e6edae5011978773eeaa589d09;p=collectd.git diff --git a/src/utils_rrdcreate.c b/src/utils_rrdcreate.c index c4e9d8ba..4ecec59d 100644 --- a/src/utils_rrdcreate.c +++ b/src/utils_rrdcreate.c @@ -213,6 +213,10 @@ static int ds_get (char ***ret, /* {{{ */ type = "COUNTER"; else if (d->type == DS_TYPE_GAUGE) type = "GAUGE"; + else if (d->type == DS_TYPE_DERIVE) + type = "DERIVE"; + else if (d->type == DS_TYPE_ABSOLUTE) + type = "ABSOLUTE"; else { ERROR ("rrdtool plugin: Unknown DS type: %i", @@ -225,14 +229,14 @@ static int ds_get (char ***ret, /* {{{ */ sstrncpy (min, "U", sizeof (min)); } else - ssnprintf (min, sizeof (min), "%lf", d->min); + ssnprintf (min, sizeof (min), "%f", d->min); if (isnan (d->max)) { sstrncpy (max, "U", sizeof (max)); } else - ssnprintf (max, sizeof (max), "%lf", d->max); + ssnprintf (max, sizeof (max), "%f", d->max); status = ssnprintf (buffer, sizeof (buffer), "DS:%s:%s:%i:%s:%s",