Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 2 additions & 4 deletions src/login/logind-user.c
Original file line number Diff line number Diff line change
Expand Up @@ -354,14 +354,12 @@ static int user_mkdir_runtime_path(User *u) {

r = mount("tmpfs", u->runtime_path, "tmpfs", MS_NODEV|MS_NOSUID, t);
if (r < 0) {
if (errno != EPERM) {
if (errno != EPERM && errno != EACCES) {
r = log_error_errno(errno, "Failed to mount per-user tmpfs directory %s: %m", u->runtime_path);
goto fail;
}

/* Lacking permissions, maybe
* CAP_SYS_ADMIN-less container? In this case,
* just use a normal directory. */
log_debug_errno(errno, "Failed to mount per-user tmpfs directory %s, assuming containerized execution, ignoring: %m", u->runtime_path);

r = chmod_and_chown(u->runtime_path, 0700, u->uid, u->gid);
if (r < 0) {
Expand Down