projects
/
systemd
/
.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
14df094
)
logind: initialize Manager object with structure initialization too
author
Lennart Poettering
<lennart@poettering.net>
Fri, 3 Aug 2018 18:20:50 +0000
(20:20 +0200)
committer
Lennart Poettering
<lennart@poettering.net>
Sat, 13 Oct 2018 10:59:29 +0000
(12:59 +0200)
src/login/logind.c
patch
|
blob
|
history
diff --git
a/src/login/logind.c
b/src/login/logind.c
index e90c8575dcd821b6edcf63b28b170d647a8017c0..e7f3a99b97facfedc4aaeb17d5f7a2e8cb7960b6 100644
(file)
--- a/
src/login/logind.c
+++ b/
src/login/logind.c
@@
-35,12
+35,14
@@
static int manager_new(Manager **ret) {
assert(ret);
- m = new
0
(Manager, 1);
+ m = new(Manager, 1);
if (!m)
return -ENOMEM;
- m->console_active_fd = -1;
- m->reserve_vt_fd = -1;
+ *m = (Manager) {
+ .console_active_fd = -1,
+ .reserve_vt_fd = -1,
+ };
m->idle_action_not_before_usec = now(CLOCK_MONOTONIC);