Skip to content

wpesrc: replace object lock usage with a new lock

Using the object lock is problematic for anything that can dispatch to another thread which is what createWPEView() does inside gst_wpe_src_start(). Using the object lock there can cause a deadlock.

One example of such a deadlock is when createWPEView is called, but another (or the same) wpesrc is on the WPEContextThread and e.g. posts a bus message. This message propagations takes and releases the object lock of numerous elements in quick succession for determining various information about the elements in the bin. If the object lock is already held, then the message propagation will block and stall bin processing (state changes, other messages) and wpe servicing any events.

Fixes #1490 (closed)

Edited by Matthew Waters

Merge request reports