Merge pull request #1201 from giuseppe/fix-segfault-rootless

rootless: do not segfault if the parent already died
This commit is contained in:
Daniel J Walsh 2018-08-02 14:42:39 -04:00 committed by GitHub
commit 9f2da6f59f
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 2 additions and 0 deletions

View File

@ -97,6 +97,8 @@ reexec_in_user_namespace(int ready)
return pid;
argv = get_cmd_line_args (ppid);
if (argv == NULL)
_exit (EXIT_FAILURE);
setenv ("_LIBPOD_USERNS_CONFIGURED", "init", 1);
setenv ("_LIBPOD_ROOTLESS_UID", uid, 1);