mirror of
git://source.winehq.org/git/wine.git
synced 2024-09-01 00:33:38 +00:00
msvcrt: In _tempnam, if TMP is set, it has a precedence over the
parameter dir.
This commit is contained in:
parent
917a801d80
commit
736cd60340
|
@ -1887,6 +1887,9 @@ __int64 _telli64(int fd)
|
|||
char *_tempnam(const char *dir, const char *prefix)
|
||||
{
|
||||
char tmpbuf[MAX_PATH];
|
||||
const char *tmp_dir = MSVCRT_getenv("TMP");
|
||||
|
||||
if (tmp_dir) dir = tmp_dir;
|
||||
|
||||
TRACE("dir (%s) prefix (%s)\n",dir,prefix);
|
||||
if (GetTempFileNameA(dir,prefix,0,tmpbuf))
|
||||
|
|
Loading…
Reference in a new issue