forked from enlightenment/efl
Eina: Fix mistake in a previous patch
Suffix length was not computed properly. Also, the change on eina_mkstemps was a @feature: add file extension support when creating temporary files
This commit is contained in:
parent
dcca057213
commit
e50bcc937c
|
@ -919,9 +919,9 @@ eina_file_mkstemp(const char *templatename, Eina_Tmpstr **path)
|
|||
* http://man7.org/linux/man-pages/man3/mkstemp.3.html#NOTES
|
||||
*/
|
||||
old_umask = umask(S_IRWXG|S_IRWXO);
|
||||
if ((XXXXXX = strstr(templatename, "XXXXXX.")) != NULL)
|
||||
if ((XXXXXX = strstr(buffer, "XXXXXX.")) != NULL)
|
||||
{
|
||||
int suffixlen = templatename + len - XXXXXX - 6;
|
||||
int suffixlen = buffer + len - XXXXXX - 6;
|
||||
fd = mkstemps(buffer, suffixlen);
|
||||
}
|
||||
else
|
||||
|
|
Loading…
Reference in New Issue