projects
/
collectd.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
0824460
)
collectd-tg: Remove use of NAN.
author
Florian Forster
<octo@collectd.org>
Fri, 3 Jul 2015 11:55:24 +0000
(13:55 +0200)
committer
Florian Forster
<octo@collectd.org>
Fri, 3 Jul 2015 11:55:24 +0000
(13:55 +0200)
This broke the build under Solaris, once again *sigh*.
collectd-tg.c: In function ‘dtime’:
collectd-tg.c:108:12: error: ‘NAN’ undeclared (first use in this function)
return NAN;
^
src/collectd-tg.c
patch
|
blob
|
history
diff --git
a/src/collectd-tg.c
b/src/collectd-tg.c
index
760162c
..
80473e0
100644
(file)
--- a/
src/collectd-tg.c
+++ b/
src/collectd-tg.c
@@
-105,7
+105,7
@@
static double dtime (void) /* {{{ */
struct timespec ts = { 0 };
if (clock_gettime (CLOCK_MONOTONIC, &ts) != 0)
-
return NAN
;
+
perror ("clock_gettime")
;
return ((double) ts.tv_sec) + (((double) ts.tv_nsec) / 1e9);
} /* }}} double dtime */