Function
GLibDirmake_tmp
Description
Creates a subdirectory in the preferred directory for temporary files (as returned by g_get_tmp_dir()).
tmpl
should be a string in the GLib file name encoding containing
a sequence of six ‘X’ characters, as the parameter to g_mkstemp().
However, unlike these functions, the template should only be a
basename, no directory components are allowed. If template is
NULL
, a default template is used.
Note that in contrast to g_mkdtemp()
(and mkdtemp()) tmpl
is not
modified, and might thus be a read-only literal string.
Available since: | 2.30 |
Parameters
tmpl |
const gchar* |
Template for directory name,
as in g_mkdtemp(), basename only, or |
|
The argument can be NULL . | |
The data is owned by the caller of the function. | |
The value is a file system path, using the OS encoding. | |
error |
GError ** |
The return location for a GError* , or NULL . |
Return value
Returns: | gchar* |
The actual name used. This string
should be freed with |
|
The caller of the function takes ownership of the data, and is responsible for freeing it. | |
The value is a file system path, using the OS encoding. |