forked from enlightenment/terminology
parent
d2321e4f65
commit
3382690cb2
|
@ -8,17 +8,10 @@ static Eet_Data_Descriptor *edd_base = NULL;
|
||||||
static const char *
|
static const char *
|
||||||
_config_home_get(void)
|
_config_home_get(void)
|
||||||
{
|
{
|
||||||
static char path[PATH_MAX] = "";
|
|
||||||
|
|
||||||
#ifdef ELM_EFREET
|
#ifdef ELM_EFREET
|
||||||
const char *tmp = efreet_config_home_get();
|
return efreet_config_home_get();
|
||||||
size_t len = eina_stringshare_strlen(tmp);
|
|
||||||
|
|
||||||
if (len + 1 < PATH_MAX)
|
|
||||||
memcpy(path, tmp, len + 1);
|
|
||||||
eina_stringshare_del(tmp);
|
|
||||||
|
|
||||||
#else
|
#else
|
||||||
|
static char path[PATH_MAX] = "";
|
||||||
const char *v = getenv("XDG_CONFIG_HOME");
|
const char *v = getenv("XDG_CONFIG_HOME");
|
||||||
if (v) eina_strlcpy(path, v, sizeof(path));
|
if (v) eina_strlcpy(path, v, sizeof(path));
|
||||||
else
|
else
|
||||||
|
@ -32,9 +25,8 @@ _config_home_get(void)
|
||||||
eina_strlcpy(path, v, sizeof(path));
|
eina_strlcpy(path, v, sizeof(path));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
#endif
|
|
||||||
|
|
||||||
return path;
|
return path;
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
|
|
Loading…
Reference in New Issue