chiark
/
gitweb
/
~ianmdlvl
/
elogind.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
build-sys: move async.[ch] to src/shared
[elogind.git]
/
src
/
shared
/
time-util.h
diff --git
a/src/shared/time-util.h
b/src/shared/time-util.h
index 0a3a98b1879f2b4b4427034f7916e1275167faaa..96f2ec8fa39b2f019d965ac210ae6e18fa534649 100644
(file)
--- a/
src/shared/time-util.h
+++ b/
src/shared/time-util.h
@@
-27,6
+27,9
@@
typedef uint64_t usec_t;
typedef uint64_t nsec_t;
typedef uint64_t usec_t;
typedef uint64_t nsec_t;
+#define NSEC_FMT "%" PRIu64
+#define USEC_FMT "%" PRIu64
+
#include "macro.h"
typedef struct dual_timestamp {
#include "macro.h"
typedef struct dual_timestamp {
@@
-58,6
+61,8
@@
typedef struct dual_timestamp {
#define FORMAT_TIMESTAMP_RELATIVE_MAX 256
#define FORMAT_TIMESPAN_MAX 64
#define FORMAT_TIMESTAMP_RELATIVE_MAX 256
#define FORMAT_TIMESPAN_MAX 64
+#define DUAL_TIMESTAMP_NULL ((struct dual_timestamp) { 0, 0 })
+
usec_t now(clockid_t clock);
dual_timestamp* dual_timestamp_get(dual_timestamp *ts);
usec_t now(clockid_t clock);
dual_timestamp* dual_timestamp_get(dual_timestamp *ts);