1
0
mirror of https://sourceware.org/git/glibc.git synced 2025-07-28 00:21:52 +03:00
* stdio-common/tempnam.c: Fix comment, it is not checked that
	TMPDIR points to a writable directory.
This commit is contained in:
Ulrich Drepper
2007-08-22 06:49:40 +00:00
parent 0f8f993cef
commit 7d55c9eb43
2 changed files with 11 additions and 7 deletions

View File

@ -19,13 +19,13 @@
#include <stdio.h>
#include <string.h>
/* Generate a unique temporary filename using up to five characters of PFX
if it is not NULL. The directory to put this file in is searched for
as follows: First the environment variable "TMPDIR" is checked.
If it contains the name of a writable directory, that directory is used.
If not and if DIR is not NULL, that value is checked. If that fails,
P_tmpdir is tried and finally "/tmp". The storage for the filename
is allocated by `malloc'. */
/* Generate a unique temporary filename using up to five characters of
PFX if it is not NULL. The directory to put this file in is
searched for as follows: First the environment variable "TMPDIR" is
checked. If it contains the name of a directory, that directory is
used. If not and if DIR is not NULL, that value is checked. If
that fails, P_tmpdir is tried and finally "/tmp". The storage for
the filename is allocated by `malloc'. */
char *
tempnam (const char *dir, const char *pfx)
{