summaryrefslogtreecommitdiff
path: root/src/shared/utmp-wtmp.c
diff options
context:
space:
mode:
authorAndreas Rammhold <andreas@rammhold.de>2017-09-29 00:37:23 +0200
committerAndreas Rammhold <andreas@rammhold.de>2017-10-02 13:09:54 +0200
commit3742095b27f8df4b195d530b52d15bc5fea70bf1 (patch)
tree3fc7c3503845b733f1d58366436c0bb672d3613a /src/shared/utmp-wtmp.c
parent01a65d4180446661732d90d23a24ab692d279295 (diff)
downloadsystemd-3742095b27f8df4b195d530b52d15bc5fea70bf1.tar.gz
tree-wide: use IN_SET where possible
In addition to the changes from #6933 this handles cases that could be matched with the included cocci file.
Diffstat (limited to 'src/shared/utmp-wtmp.c')
-rw-r--r--src/shared/utmp-wtmp.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/shared/utmp-wtmp.c b/src/shared/utmp-wtmp.c
index 9750dcd817..fc8548c5b3 100644
--- a/src/shared/utmp-wtmp.c
+++ b/src/shared/utmp-wtmp.c
@@ -234,7 +234,7 @@ int utmp_put_init_process(const char *id, pid_t pid, pid_t sid, const char *line
if (r < 0)
return r;
- if (ut_type == LOGIN_PROCESS || ut_type == USER_PROCESS) {
+ if (IN_SET(ut_type, LOGIN_PROCESS, USER_PROCESS)) {
store.ut_type = LOGIN_PROCESS;
r = write_entry_both(&store);
if (r < 0)