mirror of
https://gitlab.freedesktop.org/pulseaudio/pulseaudio.git
synced 2025-12-16 08:56:40 -05:00
Add an ifdef for when we do not have creds.
git-svn-id: file:///home/lennart/svn/public/pulseaudio/trunk@1307 fefdeb5f-60dc-0310-8127-8f9354f1896f
This commit is contained in:
parent
26201b27ec
commit
25c0640ac2
1 changed files with 3 additions and 1 deletions
|
|
@ -386,10 +386,12 @@ static void setup_complete_callback(pa_pdispatch *pd, uint32_t command, uint32_t
|
||||||
* user. This is a security measure because otherwise
|
* user. This is a security measure because otherwise
|
||||||
* data private to the user might leak. */
|
* data private to the user might leak. */
|
||||||
|
|
||||||
|
#ifdef HAVE_CREDS
|
||||||
const pa_creds *creds;
|
const pa_creds *creds;
|
||||||
if ((creds = pa_pdispatch_creds(pd)))
|
if ((creds = pa_pdispatch_creds(pd)))
|
||||||
if (getuid() == creds->uid)
|
if (getuid() == creds->uid)
|
||||||
pa_pstream_use_shm(c->pstream, 1);
|
pa_pstream_use_shm(c->pstream, 1);
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
reply = pa_tagstruct_command(c, PA_COMMAND_SET_CLIENT_NAME, &tag);
|
reply = pa_tagstruct_command(c, PA_COMMAND_SET_CLIENT_NAME, &tag);
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue