mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-11-27 12:11:13 +00:00
[MOVED FROM GST-P-FARSIGHT] error if no clock is available
20080428154850-4f0f6-38fdc4134835c457d0054301579d8cd4cbd4989a.gz
This commit is contained in:
parent
c9450ad8e2
commit
2a2d21a1f2
1 changed files with 14 additions and 5 deletions
|
@ -1028,9 +1028,10 @@ gst_live_adder_loop (gpointer data)
|
|||
buffer_timestamp = GST_BUFFER_TIMESTAMP (g_queue_peek_head (adder->buffers));
|
||||
|
||||
clock = GST_ELEMENT_CLOCK (adder);
|
||||
if (!clock)
|
||||
/* let's just push if there is no clock */
|
||||
goto push_buffer;
|
||||
|
||||
if (!clock) {
|
||||
goto no_clock;
|
||||
}
|
||||
|
||||
GST_DEBUG_OBJECT (adder, "sync to timestamp %" GST_TIME_FORMAT,
|
||||
GST_TIME_ARGS (buffer_timestamp));
|
||||
|
@ -1068,8 +1069,6 @@ gst_live_adder_loop (gpointer data)
|
|||
if (ret != GST_CLOCK_OK && ret != GST_CLOCK_EARLY)
|
||||
goto clock_error;
|
||||
|
||||
push_buffer:
|
||||
|
||||
buffer = g_queue_pop_head (adder->buffers);
|
||||
|
||||
if (!buffer)
|
||||
|
@ -1147,6 +1146,16 @@ gst_live_adder_loop (gpointer data)
|
|||
return;
|
||||
}
|
||||
|
||||
no_clock:
|
||||
{
|
||||
gst_pad_pause_task (adder->srcpad);
|
||||
GST_OBJECT_UNLOCK (adder);
|
||||
GST_ELEMENT_ERROR (adder, STREAM, MUX, ("No available clock"),
|
||||
("No available clock"));
|
||||
GST_ERROR_OBJECT (adder, "No available clock");
|
||||
return;
|
||||
}
|
||||
|
||||
pause:
|
||||
{
|
||||
const gchar *reason = gst_flow_get_name (result);
|
||||
|
|
Loading…
Reference in a new issue