mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-01-18 05:16:05 +00:00
multihandlesink: Update current time after every write
Each write will update the last_activity_time and otherwise we would compare against a too old current time and immediately timeout because current time is smaller than last activity time (overflow).
This commit is contained in:
parent
43093743e5
commit
930bfe3cbc
1 changed files with 3 additions and 3 deletions
|
@ -1691,9 +1691,6 @@ gst_multi_handle_sink_queue_buffer (GstMultiHandleSink * mhsink,
|
|||
GstMultiHandleSinkClass *mhsinkclass =
|
||||
GST_MULTI_HANDLE_SINK_GET_CLASS (mhsink);
|
||||
|
||||
g_get_current_time (&nowtv);
|
||||
now = GST_TIMEVAL_TO_TIME (nowtv);
|
||||
|
||||
CLIENTS_LOCK (mhsink);
|
||||
/* add buffer to queue */
|
||||
g_array_prepend_val (mhsink->bufqueue, buffer);
|
||||
|
@ -1719,6 +1716,9 @@ restart:
|
|||
for (clients = mhsink->clients; clients; clients = next) {
|
||||
GstMultiHandleClient *mhclient = clients->data;
|
||||
|
||||
g_get_current_time (&nowtv);
|
||||
now = GST_TIMEVAL_TO_TIME (nowtv);
|
||||
|
||||
if (cookie != mhsink->clients_cookie) {
|
||||
GST_DEBUG_OBJECT (sink, "Clients cookie outdated, restarting");
|
||||
goto restart;
|
||||
|
|
Loading…
Reference in a new issue