summaryrefslogtreecommitdiffstats
path: root/plugins/utils.h.in
diff options
context:
space:
mode:
Diffstat (limited to 'plugins/utils.h.in')
-rw-r--r--plugins/utils.h.in9
1 files changed, 4 insertions, 5 deletions
diff --git a/plugins/utils.h.in b/plugins/utils.h.in
index d88d0cb..2b668f3 100644
--- a/plugins/utils.h.in
+++ b/plugins/utils.h.in
@@ -46,16 +46,15 @@ int is_percentage (char *);
46int is_option (char *); 46int is_option (char *);
47 47
48/* generalized timer that will do milliseconds if available */ 48/* generalized timer that will do milliseconds if available */
49#ifndef HAVE_GETTIMEOFDAY 49#ifndef HAVE_STRUCT_TIMEVAL
50struct timeval { 50struct timeval {
51 long tv_sec; /* seconds */ 51 long tv_sec; /* seconds */
52 long tv_usec; /* microseconds */ 52 long tv_usec; /* microseconds */
53}; 53};
54#endif
54 55
55#define gettimeofday (tvp,tz) {\ 56#ifndef HAVE_GETTIMEOFDAY
56 tvp->tv_usec=0;\ 57int gettimeofday(struct timeval *tv, struct timezone *tz);
57 tvp->tv_sec=(long)time();\
58}
59#endif 58#endif
60 59
61double delta_time (struct timeval tv); 60double delta_time (struct timeval tv);