diff options
author | Tanu Kaskinen <tanu.kaskinen@linux.intel.com> | 2014-01-10 12:41:00 +0200 |
---|---|---|
committer | Tanu Kaskinen <tanu.kaskinen@linux.intel.com> | 2014-01-10 12:41:00 +0200 |
commit | 25b7b39367a57c1816a76f055c416d81075c591c (patch) | |
tree | 61c0981f0fab5e3e2c36062a4a97274d9b05542e | |
parent | 56e578c310c120da016051a9af2d01caf4f0a90f (diff) |
caps: Use standard macro when checking for Linux
linux and __linux are non-standard, according to
http://sourceforge.net/p/predef/wiki/OperatingSystems/
Reported-By: Damir Jelić <poljarinho@gmail.com>
-rw-r--r-- | src/daemon/caps.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/daemon/caps.c b/src/daemon/caps.c index 52c427c82..9540f0666 100644 --- a/src/daemon/caps.c +++ b/src/daemon/caps.c @@ -39,7 +39,7 @@ #include "caps.h" /* Glibc <= 2.2 has broken unistd.h */ -#if defined(linux) && (__GLIBC__ <= 2 && __GLIBC_MINOR__ <= 2) +#if defined(__linux__) && (__GLIBC__ <= 2 && __GLIBC_MINOR__ <= 2) int setresgid(gid_t r, gid_t e, gid_t s); int setresuid(uid_t r, uid_t e, uid_t s); #endif @@ -80,7 +80,7 @@ void pa_drop_root(void) { void pa_drop_caps(void) { #ifdef HAVE_SYS_CAPABILITY_H -#if defined(__linux) +#if defined(__linux__) cap_t caps; pa_assert_se(caps = cap_init()); pa_assert_se(cap_clear(caps) == 0); @@ -88,7 +88,7 @@ void pa_drop_caps(void) { pa_assert_se(cap_free(caps) == 0); #else #error "Don't know how to do capabilities on your system. Please send a patch." -#endif /* __linux */ +#endif /* __linux__ */ #else /* HAVE_SYS_CAPABILITY_H */ pa_log_warn("Normally all extra capabilities would be dropped now, but " "that's impossible because PulseAudio was built without " |