Commit 3955077f authored by Duncan Coutts's avatar Duncan Coutts
Browse files

Fix unused var warning on windows

parent d518e8f1
...@@ -536,16 +536,16 @@ void setupRtsFlags (int *argc, char *argv[]) ...@@ -536,16 +536,16 @@ void setupRtsFlags (int *argc, char *argv[])
static void checkSuid(RtsOptsEnabledEnum enabled) static void checkSuid(RtsOptsEnabledEnum enabled)
{ {
#if defined(HAVE_UNISTD_H) && defined(HAVE_SYS_TYPES_H) && !defined(mingw32_HOST_OS)
if (enabled == RtsOptsSafeOnly) { if (enabled == RtsOptsSafeOnly) {
#if defined(HAVE_UNISTD_H) && defined(HAVE_SYS_TYPES_H) && !defined(mingw32_HOST_OS)
/* This doesn't cover linux/posix capabilities like CAP_DAC_OVERRIDE, /* This doesn't cover linux/posix capabilities like CAP_DAC_OVERRIDE,
we'd have to link with -lcap for that. */ we'd have to link with -lcap for that. */
if ((getuid() != geteuid()) || (getgid() != getegid())) { if ((getuid() != geteuid()) || (getgid() != getegid())) {
errorBelch("RTS options are disabled for setuid binaries. Link with -rtsopts to enable them."); errorBelch("RTS options are disabled for setuid binaries. Link with -rtsopts to enable them.");
stg_exit(EXIT_FAILURE); stg_exit(EXIT_FAILURE);
} }
}
#endif #endif
}
} }
static void checkUnsafe(RtsOptsEnabledEnum enabled) static void checkUnsafe(RtsOptsEnabledEnum enabled)
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment