TMPNAM(3P) POSIX Programmer's Manual TMPNAM(3P)
This manual page is part of the POSIX Programmer's Manual. The Linux implementation of this interface may differ (consult the corresponding Linux manual page for details of Linux behavior), or the interface may not be implemented on Linux.
tmpnam — create a name for a temporary file
#include <stdio.h> char *tmpnam(char *s);
The functionality described on this reference page is aligned with the ISO C standard. Any conflict between the requirements described here and the ISO C standard is unintentional. This volume of POSIX.1‐20172017, except tempnam(), calls tmpnam(). The tmpnam() function need not be thread-safe if called with a NULL parameter..
No errors are defined. The following sections are informative.
Generating a Pathname The following example generates a unique pathname and stores it in the array pointed to by ptr. #include <stdio.h> ... char pathname[L_tmpnam+1]; char *ptr; ptr = tmpnam(pathname);.
None.
The tmpnam() function may be removed in a future version.
fopen(3p), open(3p), mkdtemp(3p), tempnam(3p), tmpfile(3p), unlink TMPNAM(3P)
Pages that refer to this page: stdio.h(0p), mkdtemp(3p), tempnam(3p), tmpfile(3p)