mirror of
https://gitlab.freedesktop.org/pulseaudio/pulseaudio.git
synced 2025-11-04 13:29:59 -05:00
iochannel/pstream/pdispatch: Add support for receiving file descriptors
The file descriptors are read from the iochannel just like the creds are. So instead of passing just creds (and creds_valid), we now pass the entire pa_ancil struct. Signed-off-by: David Henningsson <david.henningsson@canonical.com>
This commit is contained in:
parent
cc7a317e85
commit
06bc22b220
9 changed files with 84 additions and 31 deletions
|
|
@ -316,7 +316,7 @@ static void pstream_die_callback(pa_pstream *p, void *userdata) {
|
|||
pa_context_fail(c, PA_ERR_CONNECTIONTERMINATED);
|
||||
}
|
||||
|
||||
static void pstream_packet_callback(pa_pstream *p, pa_packet *packet, const pa_creds *creds, void *userdata) {
|
||||
static void pstream_packet_callback(pa_pstream *p, pa_packet *packet, const pa_ancil *ancil, void *userdata) {
|
||||
pa_context *c = userdata;
|
||||
|
||||
pa_assert(p);
|
||||
|
|
@ -325,7 +325,7 @@ static void pstream_packet_callback(pa_pstream *p, pa_packet *packet, const pa_c
|
|||
|
||||
pa_context_ref(c);
|
||||
|
||||
if (pa_pdispatch_run(c->pdispatch, packet, creds, c) < 0)
|
||||
if (pa_pdispatch_run(c->pdispatch, packet, ancil, c) < 0)
|
||||
pa_context_fail(c, PA_ERR_PROTOCOL);
|
||||
|
||||
pa_context_unref(c);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue