]> git.ipfire.org Git - thirdparty/systemd.git/commitdiff
login: use ERRNO_IS_PRIVILEGE() where appropriate
authorLennart Poettering <lennart@poettering.net>
Tue, 9 Jun 2020 14:13:51 +0000 (16:13 +0200)
committerLennart Poettering <lennart@poettering.net>
Tue, 9 Jun 2020 14:13:51 +0000 (16:13 +0200)
src/login/user-runtime-dir.c

index 4055c910c2d468fe840b35f1cfb5ec46eaa067c0..fdf0124c4168f06331db6d0049b01a54c9edaa94 100644 (file)
@@ -78,7 +78,7 @@ static int user_mkdir_runtime_path(
 
                 r = mount("tmpfs", runtime_path, "tmpfs", MS_NODEV|MS_NOSUID, options);
                 if (r < 0) {
-                        if (!IN_SET(errno, EPERM, EACCES)) {
+                        if (!ERRNO_IS_PRIVILEGE(errno)) {
                                 r = log_error_errno(errno, "Failed to mount per-user tmpfs directory %s: %m", runtime_path);
                                 goto fail;
                         }