rtpssrcdemux: Avoid taking streamlock out-of-band

In this change we now protect the internal srcpads list using the
stream lock and limit usage of the internal stream lock to
preventing data flowing on the other src pad type while creating
and signalling the new pad.

This fixes a deadlock with RTPBin shutdown lock. These two locks would
end up being taken in two different order, which caused a deadlock. More
generally, we should not rely on a streamlock when handling out-of-band
data, so as a side effect, we should not take a stream lock when
iterating internal links.
17 jobs for rtpssrcdemux-deadlock-fix in 115 minutes and 53 seconds (queued for 4 seconds)
Status Job ID Name Coverage
  Preparation
passed #335999
gst indent

00:00:59

passed #335998
manifest

00:00:34

 
  Build
passed #336000
build fedora x86_64

00:07:06

passed #336001
build nodebug fedora x86_64

00:07:02

passed #336002
build static fedora x86_64

00:14:25

passed #336003
build static nodebug fedora x86_64

00:10:56

 
  Test
passed #336004
check fedora

00:08:09

passed #336005
integration testsuites fedora

00:23:18

 
  Full Builds
passed #336007
build cerbero android universal

00:14:11

passed #336008
build cerbero cross win32

00:07:21

passed #336009
build cerbero cross win64

00:04:24

passed #336006
build cerbero fedora x86_64

00:09:51

 
  Full Tests
passed #336011
valgrind bad

00:07:18

passed #336012
valgrind ges

00:04:36

passed #336010
valgrind good

00:14:29

 
  Apps
passed #336013
android universal examples

00:13:05

 
  Deploy
passed #336014
documentation

00:08:40