DOC HOME SITE MAP MAN PAGES GNU INFO SEARCH PRINT BOOK
 

mktemp(3C)


mktemp -- make a unique file name

Synopsis

   #include <stdlib.h>
   

char *mktemp(char *template);

Description

mktemp replaces the contents of the string pointed to by template with a unique file name, and returns template. The string in template should look like a file name with six trailing Xs; mktemp will replace the Xs with a character string that can be used to create a unique file name.

Errors

mktemp will assign to template the empty string if it cannot create a unique name.

References

tmpfile(3S), tmpnam(3S)

Notices

mktemp can create only 26 unique file names per process for each unique template.
© 2004 The SCO Group, Inc. All rights reserved.
UnixWare 7 Release 7.1.4 - 25 April 2004