do not pass-along the environment from the kernel or initrd
This commit is contained in:
parent
82659fd757
commit
ce8aba5681
|
@ -1776,6 +1776,10 @@ finish:
|
||||||
args[i++] = sfd;
|
args[i++] = sfd;
|
||||||
args[i++] = NULL;
|
args[i++] = NULL;
|
||||||
|
|
||||||
|
/* do not pass along the environment we inherit from the kernel or initrd */
|
||||||
|
if (switch_root_dir)
|
||||||
|
clearenv();
|
||||||
|
|
||||||
assert(i <= args_size);
|
assert(i <= args_size);
|
||||||
execv(args[0], (char* const*) args);
|
execv(args[0], (char* const*) args);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue