chiark
/
gitweb
/
~ianmdlvl
/
elogind.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Prep v231.2: Move elogind specific code in logind-dbus.c to elogind-dbus.c
[elogind.git]
/
src
/
basic
/
login-util.h
diff --git
a/src/basic/login-util.h
b/src/basic/login-util.h
index a79f20c1b1e6b1a3f507de8125effeae0ae4e748..b01ee25c884cee292d2d826fc2c7f57a515e5018 100644
(file)
--- a/
src/basic/login-util.h
+++ b/
src/basic/login-util.h
@@
-1,4
+1,4
@@
-/*-*- Mode: C; c-basic-offset: 8; indent-tabs-mode: nil -*-*/
+#pragma once
/***
This file is part of systemd.
/***
This file is part of systemd.
@@
-19,8
+19,11
@@
along with systemd; If not, see <http://www.gnu.org/licenses/>.
***/
along with systemd; If not, see <http://www.gnu.org/licenses/>.
***/
-#pragma once
-
#include <stdbool.h>
#include <stdbool.h>
+#include <unistd.h>
bool session_id_valid(const char *id);
bool session_id_valid(const char *id);
+
+static inline bool logind_running(void) {
+ return access("/run/systemd/seats/", F_OK) >= 0;
+}