From 98a86d34c4d14b66df8c933cbf4dde266849f9d7 Mon Sep 17 00:00:00 2001 From: smititelu Date: Wed, 24 Feb 2016 09:15:27 +0100 Subject: [PATCH] Fix segfault when ps->component=0 --- daemon/call.c | 1 + 1 file changed, 1 insertion(+) diff --git a/daemon/call.c b/daemon/call.c index d7f960e1b..9bdf9e299 100644 --- a/daemon/call.c +++ b/daemon/call.c @@ -789,6 +789,7 @@ static void __assign_stream_fds(struct call_media *media, GQueue *intf_sfds) { il = l->data; sfd = g_queue_peek_nth(&il->list, ps->component - 1); + if (!sfd) return ; sfd->stream = ps; g_queue_push_tail(&ps->sfds, sfd);