mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-11-24 02:31:03 +00:00
rtpjitterbuffer: fix waiting timer/queue code
Changing the types from boolean to guint due to the ++ operand used on them, and only call JBUF_SIGNAL_QUEUE after settling down, or else you end up signaling the waiting code in chain() for every buffer pushed out.
This commit is contained in:
parent
d427b9bddf
commit
818b38ebdd
1 changed files with 3 additions and 3 deletions
|
@ -276,9 +276,9 @@ struct _GstRtpJitterBufferPrivate
|
|||
|
||||
RTPJitterBuffer *jbuf;
|
||||
GMutex jbuf_lock;
|
||||
gboolean waiting_queue;
|
||||
guint waiting_queue;
|
||||
GCond jbuf_queue;
|
||||
gboolean waiting_timer;
|
||||
guint waiting_timer;
|
||||
GCond jbuf_timer;
|
||||
gboolean waiting_event;
|
||||
GCond jbuf_event;
|
||||
|
@ -4134,9 +4134,9 @@ gst_rtp_jitter_buffer_loop (GstRtpJitterBuffer * jitterbuffer)
|
|||
JBUF_LOCK_CHECK (priv, flushing);
|
||||
do {
|
||||
result = handle_next_buffer (jitterbuffer);
|
||||
JBUF_SIGNAL_QUEUE (priv);
|
||||
if (G_LIKELY (result == GST_FLOW_WAIT)) {
|
||||
/* now wait for the next event */
|
||||
JBUF_SIGNAL_QUEUE (priv);
|
||||
JBUF_WAIT_EVENT (priv, flushing);
|
||||
result = GST_FLOW_OK;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue