Merge pull request #13102 from mbiebl/nologin-path

meson: make nologin path build time configurable
This commit is contained in:
Zbigniew Jędrzejewski-Szmek
2019-07-18 17:17:23 +02:00
committed by GitHub
23 changed files with 62 additions and 61 deletions
+2 -2
View File
@@ -148,7 +148,7 @@ static int synthesize_user_creds(
*home = FLAGS_SET(flags, USER_CREDS_CLEAN) ? NULL : "/";
if (shell)
*shell = FLAGS_SET(flags, USER_CREDS_CLEAN) ? NULL : "/sbin/nologin";
*shell = FLAGS_SET(flags, USER_CREDS_CLEAN) ? NULL : NOLOGIN;
return 0;
}
@@ -538,7 +538,7 @@ int get_shell(char **_s) {
}
if (synthesize_nobody() &&
u == UID_NOBODY) {
s = strdup("/sbin/nologin");
s = strdup(NOLOGIN);
if (!s)
return -ENOMEM;