multiudpsink: keep client list consistent during removals
authorTim-Philipp Müller <tim@centricular.com>
Tue, 24 Jun 2014 00:15:25 +0000 (01:15 +0100)
committerTim-Philipp Müller <tim@centricular.com>
Tue, 16 Dec 2014 20:26:36 +0000 (20:26 +0000)
commit54a9a436ba04e47000300377f899a5d3858c74d8
tree96c3dcca5cd79e2c3d5d44559d321c6ac9c3c3ff
parentfa3ef2e54ceb7437368dd6c61ef4531adc3068dd
multiudpsink: keep client list consistent during removals

We unlock and re-lock the client lock while emitting the
removed signal, which causes inconsistencies in the client
list vs. the client counts. Instead, remove the client from
the list already before emitting the signal and put it into
a temporary list of clients to be removed. That way things
look consistent to the streaming thread, but signal callbacks
can still do things like get stats from removed clients.
gst/udp/gstmultiudpsink.c
gst/udp/gstmultiudpsink.h