core: Basic implementation of Scheduler
refs #1119 (http://redmine.named-data.net/issues/1119)
Change-Id: I1783857452941794a2538534d3492d30ac58dd25
diff --git a/daemon/core/time.cpp b/daemon/core/time.cpp
index e3a2cda..712779d 100644
--- a/daemon/core/time.cpp
+++ b/daemon/core/time.cpp
@@ -24,7 +24,7 @@
throw std::runtime_error("clock_gettime");
}
- return t.tv_sec * 1000000000 + t.tv_nsec;
+ return Point(time::seconds(t.tv_sec) + time::nanoseconds(t.tv_nsec));
#else
// fallback to wall clock time
@@ -36,7 +36,7 @@
throw std::runtime_error("gettimeofday");
}
- return tv.tv_sec * 1000000000 + tv.tv_usec * 1000;
+ return Point(time::seconds(tv.tv_sec) + time::microseconds(tv.tv_usec));
#endif
}