rtpjitterbuffer: Avoid deadlock on flush
authorEdward Hervey <edward@centricular.com>
Sat, 30 May 2020 06:55:19 +0000 (08:55 +0200)
committerEdward Hervey <bilboed@bilboed.com>
Mon, 8 Jun 2020 11:34:26 +0000 (13:34 +0200)
commit54810bf44f27d9c180730f58f16f6e172c7b0bc8
tree9c6190a50e92a6a5a47adc7af753fa49e577c6f2
parentf63299ff2f774e858c384cd3998b203541a9631a
rtpjitterbuffer: Avoid deadlock on flush

When a GST_EVENT_FLUSH_START reaches the jitterbuffer, there is a chance that
our task is currently blocking waiting for a timer.

There was two problems:
* That wait wasn't checking for flushing situations
* The flushing handling wasn't waking up that conditional (to check whether it
should abort)

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/merge_requests/608>
gst/rtpmanager/gstrtpjitterbuffer.c