chiark
/
gitweb
/
~ianmdlvl
/
elogind.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
| inline |
side by side
dbus1-generator: fix array sentinal
[elogind.git]
/
src
/
shared
/
util.c
diff --git
a/src/shared/util.c
b/src/shared/util.c
index 88fd78ec8d61f5b0de698d085e9e68c2ec83b346..7d753e448a4f5da69b8d86045d90b6388a85a921 100644
(file)
--- a/
src/shared/util.c
+++ b/
src/shared/util.c
@@
-7670,6
+7670,9
@@
int fd_setcrtime(int fd, usec_t usec) {
assert(fd >= 0);
+ if (usec <= 0)
+ usec = now(CLOCK_REALTIME);
+
le = htole64((uint64_t) usec);
if (fsetxattr(fd, "user.crtime_usec", &le, sizeof(le), 0) < 0)
return -errno;