forked from enlightenment/efl
eina: make sure to cleanup the right string.
This commit is contained in:
parent
8937fd4fc9
commit
58b194e0ad
|
@ -344,6 +344,7 @@ EAPI char *
|
|||
eina_file_path_sanitize(const char *path)
|
||||
{
|
||||
Eina_Tmpstr *result = NULL;
|
||||
char *r;
|
||||
size_t len;
|
||||
|
||||
if (!path) return NULL;
|
||||
|
@ -358,7 +359,10 @@ eina_file_path_sanitize(const char *path)
|
|||
else
|
||||
result = path;
|
||||
|
||||
return _eina_file_escape(eina_file_cleanup(result), len);
|
||||
r = _eina_file_escape(strdup(result ? result : ""), len);
|
||||
if (result != path) eina_tmpstr_del(result);
|
||||
|
||||
return r;
|
||||
}
|
||||
|
||||
EAPI Eina_File *
|
||||
|
|
Loading…
Reference in New Issue