diff options
author | Peter Meerwald <pmeerw@pmeerw.net> | 2014-08-12 23:33:12 +0200 |
---|---|---|
committer | Peter Meerwald <p.meerwald@bct-electronic.com> | 2014-08-18 23:21:59 +0200 |
commit | fd193273271af5cc3e15c7b2c89dbd03704393ae (patch) | |
tree | e9be5b74a6b3bc7ba52bc5f0b418f8a5f76f72af /src | |
parent | 7974a17d1d703f28df16f268f66b3d8cb232e04b (diff) |
srbchannel: pa_srbchannel_new() may fail
return from setup_srbchannel() when pa_srbchannel_new() fails
pa_srbchannel_new() depends on HAVE_SYS_EVENTFD_H, e.g. Debian/kFreeBSD doesn't
have it
Signed-off-by: Peter Meerwald <pmeerw@pmeerw.net>
Acked-by: David Henningsson <david.henningsson@canonical.com>
Diffstat (limited to 'src')
-rw-r--r-- | src/pulsecore/protocol-native.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/pulsecore/protocol-native.c b/src/pulsecore/protocol-native.c index 5f2c35d24..93db15758 100644 --- a/src/pulsecore/protocol-native.c +++ b/src/pulsecore/protocol-native.c @@ -2612,8 +2612,12 @@ static void setup_srbchannel(pa_native_connection *c) { return; } - pa_log_debug("Enabling srbchannel..."); srb = pa_srbchannel_new(c->protocol->core->mainloop, c->protocol->core->rw_mempool); + if (!srb) { + pa_log_debug("Failed to create srbchannel"); + return; + } + pa_log_debug("Enabling srbchannel..."); pa_srbchannel_export(srb, &srbt); /* Send enable command to client */ |