chiark
/
gitweb
/
~ianmdlvl
/
elogind.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
| inline |
side by side
namespace: rework namespace support
[elogind.git]
/
src
/
shared
/
util.c
diff --git
a/src/shared/util.c
b/src/shared/util.c
index 946b7d53f95c1144b44705a4082a4e458ed24443..e615195af580711d4c919ad4461325612c6e9f80 100644
(file)
--- a/
src/shared/util.c
+++ b/
src/shared/util.c
@@
-3011,7
+3011,8
@@
unsigned long long random_ull(void) {
uint64_t ull;
ssize_t r;
- if ((fd = open("/dev/urandom", O_RDONLY|O_CLOEXEC|O_NOCTTY)) < 0)
+ fd = open("/dev/urandom", O_RDONLY|O_CLOEXEC|O_NOCTTY);
+ if (fd < 0)
goto fallback;
r = loop_read(fd, &ull, sizeof(ull), true);