chiark / gitweb /
Cleaned up more unneeded functions and types in:
[elogind.git] / src / basic / time-util.c
index 15185a2bb3e565222777e0e84a050c82cb00ca70..17d3da6fa296c5821300f2767907375f9dc201fb 100644 (file)
@@ -37,6 +37,8 @@ usec_t now(clockid_t clock_id) {
         return timespec_load(&ts);
 }
 
+/// UNNEEDED by elogind
+#if 0
 nsec_t now_nsec(clockid_t clock_id) {
         struct timespec ts;
 
@@ -44,6 +46,7 @@ nsec_t now_nsec(clockid_t clock_id) {
 
         return timespec_load_nsec(&ts);
 }
+#endif // 0
 
 dual_timestamp* dual_timestamp_get(dual_timestamp *ts) {
         assert(ts);
@@ -98,7 +101,6 @@ dual_timestamp* dual_timestamp_from_monotonic(dual_timestamp *ts, usec_t u) {
 
         return ts;
 }
-#endif // 0
 
 dual_timestamp* dual_timestamp_from_boottime_or_monotonic(dual_timestamp *ts, usec_t u) {
         int64_t delta;
@@ -124,7 +126,7 @@ dual_timestamp* dual_timestamp_from_boottime_or_monotonic(dual_timestamp *ts, us
 
         return ts;
 }
-
+#endif // 0
 
 usec_t timespec_load(const struct timespec *ts) {
         assert(ts);
@@ -798,6 +800,8 @@ int parse_sec(const char *t, usec_t *usec) {
         return 0;
 }
 
+/// UNNEEDED by elogind
+#if 0
 int parse_nsec(const char *t, nsec_t *nsec) {
         static const struct {
                 const char *suffix;
@@ -923,8 +927,6 @@ int parse_nsec(const char *t, nsec_t *nsec) {
         return 0;
 }
 
-/// UNNEEDED by elogind
-#if 0
 bool ntp_synced(void) {
         struct timex txc = {};
 
@@ -1041,7 +1043,6 @@ bool timezone_is_valid(const char *name) {
 
         return true;
 }
-#endif // 0
 
 clockid_t clock_boottime_or_monotonic(void) {
         static clockid_t clock = -1;
@@ -1087,3 +1088,4 @@ int get_timezone(char **tz) {
         *tz = z;
         return 0;
 }
+#endif // 0