Museum

Home

Lab Overview

Retrotechnology Articles

Online Manuals

⇒ mktemp(S) — System V/386 Software Development System 3.2.2b

Media Vault

Software Library

Restoration Projects

Artifacts Sought



     MKTEMP(S)                 UNIX System V                 MKTEMP(S)



     Name
          mktemp - make a unique file name

     Syntax
          char *mktemp (template)
          char *template;

     Description
          The mktemp function replaces the contents of the string
          pointed to by template by a unique file name, and returns
          the address of template.  The string in template should look
          like a file name with six trailing Xs; mktemp will replace
          the Xs with a letter and the current process ID.  The letter
          will be chosen so that the resulting name does not duplicate
          an existing file.

     See Also
          getpid(S), tmpfile(S), tmpnam(S)

     Diagnostic
          The mktemp function will assign to template the NULL string
          if it cannot create a unique name.

     Notes
          If called more than 17,576 times in a single process, this
          function will start recycling previously used names.

     Standards Conformance
          mktemp is conformant with:
          AT&T SVID Issue 2, Select Code 307-127;
          and The X/Open Portability Guide II of January 1987.

                                             (printed 6/20/89)



Typewritten Software • bear@typewritten.org • Edmonds, WA 98026