diff options
author | Lennart Poettering <lennart@poettering.net> | 2011-06-30 02:16:07 +0200 |
---|---|---|
committer | Lennart Poettering <lennart@poettering.net> | 2011-06-30 02:16:07 +0200 |
commit | e6061ab2afecfaaa0d0797b88f9a4f53720b31ee (patch) | |
tree | 28c036ae8da1ab7867adf76d975455ce219a4f0c /src | |
parent | 530345e78299951c3a151c93d77e5adbe421bc68 (diff) |
logind: make sure to create/run/systemd/sessions before we try to place a fifo in it
Diffstat (limited to 'src')
-rw-r--r-- | src/logind-session.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/logind-session.c b/src/logind-session.c index bc1b9b77ca..cadf93283a 100644 --- a/src/logind-session.c +++ b/src/logind-session.c @@ -787,6 +787,10 @@ int session_create_fifo(Session *s) { /* Create FIFO */ if (!s->fifo_path) { + r = safe_mkdir("/run/systemd/sessions", 0755, 0, 0); + if (r < 0) + return r; + if (asprintf(&s->fifo_path, "/run/systemd/sessions/%s.ref", s->id) < 0) return -ENOMEM; |