forked from enlightenment/efl
efreet: make geteuid an optional function.
This commit is contained in:
parent
e888a07c0a
commit
e920c2cc76
|
@ -518,6 +518,7 @@ mkdirat \
|
||||||
mtrace \
|
mtrace \
|
||||||
realpath \
|
realpath \
|
||||||
strlcpy \
|
strlcpy \
|
||||||
|
geteuid \
|
||||||
])
|
])
|
||||||
|
|
||||||
AC_FUNC_ALLOCA
|
AC_FUNC_ALLOCA
|
||||||
|
|
|
@ -335,6 +335,7 @@ efreet_dirs_init(void)
|
||||||
}
|
}
|
||||||
else if ((st.st_mode & 0777) != 0700)
|
else if ((st.st_mode & 0777) != 0700)
|
||||||
{
|
{
|
||||||
|
#ifdef HAVE_GETEUID
|
||||||
if (st.st_uid == geteuid())
|
if (st.st_uid == geteuid())
|
||||||
{
|
{
|
||||||
ERR("XDG_RUNTIME_DIR=%s is mode %o, changing to 0700",
|
ERR("XDG_RUNTIME_DIR=%s is mode %o, changing to 0700",
|
||||||
|
@ -346,6 +347,7 @@ efreet_dirs_init(void)
|
||||||
eina_stringshare_replace(&xdg_runtime_dir, NULL);
|
eina_stringshare_replace(&xdg_runtime_dir, NULL);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
/* hostname */
|
/* hostname */
|
||||||
if (gethostname(buf, sizeof(buf)) < 0)
|
if (gethostname(buf, sizeof(buf)) < 0)
|
||||||
|
|
Loading…
Reference in New Issue