execute: no need to synthesize $HOME for uid==0 again, get_home_dir() already does that

This commit is contained in:
Lennart Poettering 2019-03-07 11:00:40 +01:00
parent 7bbead1d0b
commit 9e73208afc
1 changed files with 0 additions and 6 deletions

View File

@ -2742,12 +2742,6 @@ static int acquire_home(const ExecContext *c, uid_t uid, const char** home, char
if (!c->working_directory_home)
return 0;
if (uid == 0) {
/* Hardcode /root as home directory for UID 0 */
*home = "/root";
return 1;
}
r = get_home_dir(buf);
if (r < 0)
return r;