timespec_to_sec
static double timespec_to_sec(const struct timespec *);
last = timespec_to_sec(&clear_cache) + maxwait;
d_last = last - timespec_to_sec(&now);
static double timespec_to_sec(const struct timespec *tp);
last = timespec_to_sec(&now) + deadline;
d_last = last - timespec_to_sec(&now);