mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-08 19:58:09 +02:00
util: simplify logic in __normal_user()
Cc: mesa-stable Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/27378>
This commit is contained in:
parent
6c570f7a98
commit
afd4e633ee
1 changed files with 4 additions and 4 deletions
|
|
@ -396,11 +396,11 @@ debug_get_option_ ## suffix (void) \
|
||||||
static inline bool
|
static inline bool
|
||||||
__normal_user(void)
|
__normal_user(void)
|
||||||
{
|
{
|
||||||
#if !defined(_WIN32)
|
#if defined(_WIN32)
|
||||||
if (geteuid() != getuid())
|
|
||||||
return false;
|
|
||||||
#endif
|
|
||||||
return true;
|
return true;
|
||||||
|
#else
|
||||||
|
return geteuid() == getuid();
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
#define DEBUG_GET_ONCE_BOOL_OPTION(sufix, name, dfault) \
|
#define DEBUG_GET_ONCE_BOOL_OPTION(sufix, name, dfault) \
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue