X-Git-Url: https://git.octo.it/?p=collectd.git;a=blobdiff_plain;f=src%2Fexec.c;h=3f68e8bbcf1ab26d6f195d80c5ec0213c562a732;hp=cb6844b86ce928696f8111b316fd61cf1dfd4704;hb=9817e7298bd6c364fa17347327af54adf048bd21;hpb=061c3c091d725d58dfe1e7525a8d72a1ea389a8a diff --git a/src/exec.c b/src/exec.c index cb6844b8..3f68e8bb 100644 --- a/src/exec.c +++ b/src/exec.c @@ -23,6 +23,7 @@ * Peter Holik **/ +#define _DEFAULT_SOURCE #define _BSD_SOURCE /* For setgroups */ #include "collectd.h" @@ -744,8 +745,8 @@ static void *exec_notification_one (void *arg) /* {{{ */ fprintf (fh, "Severity: %s\n" - "Time: %u\n", - severity, (unsigned int)CDTIME_T_TO_TIME_T(n->time)); + "Time: %.3f\n", + severity, CDTIME_T_TO_DOUBLE (n->time)); /* Print the optional fields */ if (strlen (n->host) > 0)