mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-11-20 00:31:13 +00:00
multihandlesink: fix one bug in multisocketsink refactoring
This commit is contained in:
parent
c024274261
commit
d21c42a709
3 changed files with 11 additions and 11 deletions
|
@ -855,6 +855,8 @@ restart:
|
|||
next = g_list_next (clients);
|
||||
|
||||
mhclient->status = GST_CLIENT_STATUS_REMOVED;
|
||||
/* the next call changes the list, which is why we iterate
|
||||
* with a temporary next pointer */
|
||||
gst_multi_fd_sink_remove_client_link (sink, clients);
|
||||
}
|
||||
gst_poll_restart (sink->fdset);
|
||||
|
|
|
@ -782,7 +782,7 @@ done:
|
|||
void
|
||||
gst_multi_socket_sink_clear (GstMultiHandleSink * mhsink)
|
||||
{
|
||||
GList *clients;
|
||||
GList *clients, *next;
|
||||
guint32 cookie;
|
||||
GstMultiSocketSink *sink = GST_MULTI_SOCKET_SINK (mhsink);
|
||||
|
||||
|
@ -791,7 +791,7 @@ gst_multi_socket_sink_clear (GstMultiHandleSink * mhsink)
|
|||
CLIENTS_LOCK (sink);
|
||||
restart:
|
||||
cookie = sink->clients_cookie;
|
||||
for (clients = sink->clients; clients; clients = clients->next) {
|
||||
for (clients = sink->clients; clients; clients = next) {
|
||||
GstMultiHandleClient *mhclient;
|
||||
|
||||
if (cookie != sink->clients_cookie) {
|
||||
|
@ -800,7 +800,11 @@ restart:
|
|||
}
|
||||
|
||||
mhclient = (GstMultiHandleClient *) clients->data;
|
||||
next = g_list_next (clients);
|
||||
|
||||
mhclient->status = GST_CLIENT_STATUS_REMOVED;
|
||||
/* the next call changes the list, which is why we iterate
|
||||
* with a temporary next pointer */
|
||||
gst_multi_socket_sink_remove_client_link (sink, clients);
|
||||
}
|
||||
|
||||
|
|
|
@ -587,9 +587,7 @@ GST_START_TEST (test_burst_client_bytes)
|
|||
ASSERT_SET_STATE (sink, GST_STATE_NULL, GST_STATE_CHANGE_SUCCESS);
|
||||
cleanup_multisocketsink (sink);
|
||||
|
||||
// FIXME for slomo: the refcount is now 3 instead of 1 ?
|
||||
// ASSERT_CAPS_REFCOUNT (caps, "caps", 1);
|
||||
ASSERT_CAPS_REFCOUNT (caps, "caps", 3);
|
||||
ASSERT_CAPS_REFCOUNT (caps, "caps", 1);
|
||||
gst_caps_unref (caps);
|
||||
}
|
||||
|
||||
|
@ -690,9 +688,7 @@ GST_START_TEST (test_burst_client_bytes_keyframe)
|
|||
ASSERT_SET_STATE (sink, GST_STATE_NULL, GST_STATE_CHANGE_SUCCESS);
|
||||
cleanup_multisocketsink (sink);
|
||||
|
||||
// FIXME for slomo: the refcount is now 3 instead of 1 ?
|
||||
// ASSERT_CAPS_REFCOUNT (caps, "caps", 1);
|
||||
ASSERT_CAPS_REFCOUNT (caps, "caps", 3);
|
||||
ASSERT_CAPS_REFCOUNT (caps, "caps", 1);
|
||||
gst_caps_unref (caps);
|
||||
}
|
||||
|
||||
|
@ -798,9 +794,7 @@ GST_START_TEST (test_burst_client_bytes_with_keyframe)
|
|||
ASSERT_SET_STATE (sink, GST_STATE_NULL, GST_STATE_CHANGE_SUCCESS);
|
||||
cleanup_multisocketsink (sink);
|
||||
|
||||
// FIXME for slomo: the refcount is now 3 instead of 1 ?
|
||||
// ASSERT_CAPS_REFCOUNT (caps, "caps", 1);
|
||||
ASSERT_CAPS_REFCOUNT (caps, "caps", 3);
|
||||
ASSERT_CAPS_REFCOUNT (caps, "caps", 1);
|
||||
gst_caps_unref (caps);
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue