mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-06-04 22:48:54 +00:00
transcodebin: fix caps leak
encodecaps was leaked if the profile has restrictions.
This commit is contained in:
parent
91a033a85e
commit
54d8360baa
1 changed files with 5 additions and 3 deletions
|
@ -293,14 +293,16 @@ make_decodebin (GstTranscodeBin * self)
|
|||
gst_encoding_container_profile_get_profiles
|
||||
(GST_ENCODING_CONTAINER_PROFILE (self->profile)); tmp;
|
||||
tmp = tmp->next) {
|
||||
GstCaps *encodecaps = gst_encoding_profile_get_format (tmp->data);
|
||||
GstCaps *restrictions =
|
||||
gst_encoding_profile_get_restriction (tmp->data);
|
||||
|
||||
if (!restrictions)
|
||||
if (!restrictions) {
|
||||
GstCaps *encodecaps = gst_encoding_profile_get_format (tmp->data);
|
||||
|
||||
gst_caps_append (decodecaps, encodecaps);
|
||||
else
|
||||
} else {
|
||||
gst_caps_unref (restrictions);
|
||||
}
|
||||
}
|
||||
}
|
||||
g_object_set (self->decodebin, "caps", decodecaps, NULL);
|
||||
|
|
Loading…
Reference in a new issue