Internationalization and localization tools


File and Path Function

char *mkdtemp(char *template);

Internationalization (I18n) Function Overview

The mkdtemp function creates a directory with a unique name. If it succeeds, it overwrites template with the name of the directory, and returns template. As with mktemp and mkstemp, template should be a string ending with XXXXXX.

If mkdtemp cannot create an uniquely named directory, it returns NULL and sets errno appropriately. If template does not end with XXXXXX, mkdtemp returns NULL and does not modify template. errno will be set to EINVAL in this case. The directory is created using mode 0700.

I18n Issues

On ANSI UTF-16 platforms, use a conversion function to convert the wide-character string to a multibyte-character string and then call mkdtemp.

See Pathnames for a discussion of path and filename considerations in an internationalized application.

Recommended Replacements*

*If you're already using the recommended function, see I18n Issues for other reasons why Globalyzer is detecting the function.

File and Path Functions

 

Lingoport internationalization and localization services and software