rtpmanagerbad: reduce lock in rtpsink
authorMarc Leeman <m.leeman@televic.com>
Wed, 19 Feb 2020 16:07:23 +0000 (17:07 +0100)
committerMarc Leeman <m.leeman@televic.com>
Fri, 21 Feb 2020 11:16:21 +0000 (12:16 +0100)
gst/rtp/gstrtpsink.c

index 24becc1..09f3cde 100644 (file)
@@ -251,11 +251,11 @@ gst_rtp_sink_request_new_pad (GstElement * element,
     return NULL;
 
   GST_RTP_SINK_LOCK (self);
-
   pad = gst_element_get_request_pad (self->rtpbin, "send_rtp_sink_%u");
+  GST_RTP_SINK_UNLOCK (self);
+
   g_return_val_if_fail (pad != NULL, NULL);
 
-  GST_RTP_SINK_UNLOCK (self);
 
   return pad;
 }