webrtcbin: Avoid access of freed memory
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/2256>
This commit is contained in:
parent
27dea62304
commit
c5b1eecb69
@ -1886,7 +1886,6 @@ _find_codec_preferences (GstWebRTCBin * webrtc,
|
|||||||
|
|
||||||
caps = _query_pad_caps (webrtc, rtp_trans, pad, filter, error);
|
caps = _query_pad_caps (webrtc, rtp_trans, pad, filter, error);
|
||||||
}
|
}
|
||||||
gst_object_unref (pad);
|
|
||||||
|
|
||||||
if (*error)
|
if (*error)
|
||||||
goto out;
|
goto out;
|
||||||
@ -1940,6 +1939,8 @@ _find_codec_preferences (GstWebRTCBin * webrtc,
|
|||||||
|
|
||||||
out:
|
out:
|
||||||
|
|
||||||
|
if (pad)
|
||||||
|
gst_object_unref (pad);
|
||||||
if (codec_preferences)
|
if (codec_preferences)
|
||||||
gst_caps_unref (codec_preferences);
|
gst_caps_unref (codec_preferences);
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user