mirror of
https://github.com/opnsense/src.git
synced 2026-05-28 04:12:45 -04:00
Ignore TMPDIR if the application is setugid.
MFC after: 2 weeks
This commit is contained in:
parent
57185ffa08
commit
61bdf123c3
1 changed files with 2 additions and 1 deletions
|
|
@ -61,7 +61,8 @@ tmpfile()
|
|||
char *buf;
|
||||
const char *tmpdir;
|
||||
|
||||
tmpdir = getenv("TMPDIR");
|
||||
if (issetugid() == 0)
|
||||
tmpdir = getenv("TMPDIR");
|
||||
if (tmpdir == NULL)
|
||||
tmpdir = _PATH_TMP;
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue