From a3ef36da3e2ba471a17f8c6291d171c047f66cbf Mon Sep 17 00:00:00 2001 From: "Anna (navi) Figueiredo Gomes" Date: Tue, 20 Jun 2023 08:09:05 -0300 Subject: librc: disallow running --user without XDG_RUNTIME_DIR set since openrc-pam now sets XDG_RUNTIME_DIR in case it's unset, we can expect it to exist. Signed-off-by: Anna (navi) Figueiredo Gomes --- src/librc/librc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src') diff --git a/src/librc/librc.c b/src/librc/librc.c index 58219b40..53625759 100644 --- a/src/librc/librc.c +++ b/src/librc/librc.c @@ -1477,7 +1477,7 @@ rc_svcdir(void) if ((env = getenv("XDG_RUNTIME_DIR"))) { xasprintf(&path, "%s/%s", env, RC_USER_CONF_FOLDER); } else { - xasprintf(&path, "/tmp/%s/%d/", RC_USER_CONF_FOLDER, getuid()); + eerrorx("XDG_RUNTIME_DIR not set in user mode"); } } else { #endif -- cgit v1.2.3