X-Git-Url: http://git.tuebingen.mpg.de/?p=dss.git;a=blobdiff_plain;f=time.c;h=b54e34c565f7be55b6370f468bc8e4c811809f70;hp=18366cd886946fd5433f6f0bfec3c486a8ffb8b4;hb=222b3355ee441ab4a310ef2830181ffd4300223b;hpb=27edbe5dcf615a3c445f719b5833af4d392c5874 diff --git a/time.c b/time.c index 18366cd..b54e34c 100644 --- a/time.c +++ b/time.c @@ -1,6 +1,13 @@ #include #include #include +#include +#include + +#include "gcc-compat.h" +#include "error.h" +#include "string.h" +#include "log.h" /* * Copyright (C) 2005-2008 Andre Noll @@ -129,3 +136,11 @@ void tv_divide(const unsigned long divisor, const struct timeval *tv, result->tv_sec = x / 1000 / 1000; result->tv_usec = x % (1000 * 1000); } + +int64_t get_current_time(void) +{ + time_t now; + time(&now); + DSS_DEBUG_LOG("now: %lli\n", (long long) now); + return (int64_t)now; +}