aboutsummaryrefslogtreecommitdiff
path: root/plugins/utils.c
diff options
context:
space:
mode:
Diffstat (limited to 'plugins/utils.c')
-rw-r--r--plugins/utils.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/plugins/utils.c b/plugins/utils.c
index c2261dc3..518caa8c 100644
--- a/plugins/utils.c
+++ b/plugins/utils.c
@@ -287,6 +287,16 @@ delta_time (struct timeval tv)
+long
+deltime (struct timeval tv)
+{
+ struct timeval now;
+ gettimeofday (&now, NULL);
+ return (now.tv_sec - tv.tv_sec)*1000000 + now.tv_usec - tv.tv_usec;
+}
+
+
+
void
strip (char *buffer)