merge branch 'pr-2015'

Use getenv not secure_getenv

LGTMs: @crosbymichael @cyphar
Closes #2015
This commit is contained in:
Aleksa Sarai 2019-03-16 17:30:56 +11:00
commit f56b4cbead
No known key found for this signature in database
GPG Key ID: 9E18AA267DDB8DB4
1 changed files with 2 additions and 2 deletions

View File

@ -249,7 +249,7 @@ static int make_execfd(int *fdtype)
{ {
int fd = -1; int fd = -1;
char template[PATH_MAX] = {0}; char template[PATH_MAX] = {0};
char *prefix = secure_getenv("_LIBCONTAINER_STATEDIR"); char *prefix = getenv("_LIBCONTAINER_STATEDIR");
if (!prefix || *prefix != '/') if (!prefix || *prefix != '/')
prefix = "/tmp"; prefix = "/tmp";
@ -351,7 +351,7 @@ static int try_bindfd(void)
{ {
int fd, ret = -1; int fd, ret = -1;
char template[PATH_MAX] = {0}; char template[PATH_MAX] = {0};
char *prefix = secure_getenv("_LIBCONTAINER_STATEDIR"); char *prefix = getenv("_LIBCONTAINER_STATEDIR");
if (!prefix || *prefix != '/') if (!prefix || *prefix != '/')
prefix = "/tmp"; prefix = "/tmp";