mktemp() General Function mktemp() Generate a temporary file name char *mktemp(pattern) char *pattern; mktemp generates a unique file name. It can be used, for ex- ample, to name intermediate data files. pattern must consist of a string with six X's at the end. mktemp replaces these X's with the five-digit process id of the requesting process and a letter that is changed for each subsequent call. mktemp returns pat- tern. For example, the call mktemp("/tmp/sortXXXXXX"); might return the name /tmp/sort01234a. It is normal practice to place temporary files in the directory /tmp. The start of the file name identifies the originator of the file. ***** See Also ***** general functions, getpid(), tempnam(), tmpnam() COHERENT Lexicon Page 1