Bug 66846 - caps.c fails to compile on Windows
Summary: caps.c fails to compile on Windows
Status: RESOLVED FIXED
Alias: None
Product: PulseAudio
Classification: Unclassified
Component: daemon (show other bugs)
Version: unspecified
Hardware: Other All
: medium normal
Assignee: pulseaudio-bugs
QA Contact: pulseaudio-bugs
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2013-07-12 07:56 UTC by Pierre Ossman
Modified: 2013-07-14 10:29 UTC (History)
1 user (show)

See Also:
i915 platform:
i915 features:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Pierre Ossman 2013-07-12 07:56:50 UTC
daemon/caps.c: In function 'pa_drop_root':
daemon/caps.c:77:9: error: 'uid' undeclared (first use in this function)
daemon/caps.c:77:9: note: each undeclared identifier is reported only once for each function it appears in
make[7]: *** [pulseaudio-caps.o] Error 1

You can't be looking at uid if the system doesn't have getuid(). :)

Fix:

Index: src/daemon/caps.c
===================================================================
--- src/daemon/caps.c	(revision 27650)
+++ src/daemon/caps.c	(working copy)
@@ -72,10 +72,10 @@
     pa_assert_se(geteuid() == uid);
     pa_assert_se(getgid() == gid);
     pa_assert_se(getegid() == gid);
-#endif
 
     if (uid != 0)
         pa_drop_caps();
+#endif
 }
 
 void pa_drop_caps(void) {


Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.