diff options
author | Ronny Chevalier <chevalier.ronny@gmail.com> | 2014-10-11 18:45:11 +0200 |
---|---|---|
committer | Lennart Poettering <lennart@poettering.net> | 2014-10-21 00:38:30 +0200 |
commit | e4746b57387ffaf8be01c177ed4bbf02c8088341 (patch) | |
tree | 12d3f25f511a05c381005f5d08a2585071efb0bd /src/shared/time-util.h | |
parent | 6dab5bb18151c80fc39bd51f03dcff40b920de3e (diff) |
util: avoid duplication of TIME_T_MAX
Diffstat (limited to 'src/shared/time-util.h')
-rw-r--r-- | src/shared/time-util.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/shared/time-util.h b/src/shared/time-util.h index 05369d295b..b55a660bb0 100644 --- a/src/shared/time-util.h +++ b/src/shared/time-util.h @@ -65,6 +65,8 @@ typedef struct dual_timestamp { #define FORMAT_TIMESTAMP_RELATIVE_MAX 256 #define FORMAT_TIMESPAN_MAX 64 +#define TIME_T_MAX (time_t)((1UL << ((sizeof(time_t) << 3) - 1)) - 1) + #define DUAL_TIMESTAMP_NULL ((struct dual_timestamp) { 0, 0 }) usec_t now(clockid_t clock); |