/*
- * $Id: util.c,v 1.34 1997/10/25 17:22:31 wessels Exp $
+ * $Id: util.c,v 1.35 1997/11/15 05:43:29 wessels Exp $
*
* DEBUG:
* AUTHOR: Harvest Derived
(t2.tv_usec - t1.tv_usec);
}
+double
+tvSubDsec(struct timeval t1, struct timeval t2)
+{
+ return (double) (t2.tv_sec - t1.tv_sec) +
+ (double) (t2.tv_usec - t1.tv_usec) / 1000000.0;
+}
+
/*
* xstrncpy() - similar to strncpy(3) but terminates string
* always with '\0' if n != 0, and doesn't do padding