mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-02-20 21:16:24 +00:00
caps: No need to require writable caps for _append/_merge second caps
The second caps ownership is transfered, no need to require it to be writable from the caller function. Instead, _append and _merge make it writable on their own. Discovered because of an assertion on encoding-profile.c in _get_input_caps using _merge but not passing writable caps.
This commit is contained in:
parent
b046ba6e3a
commit
27ce89812a
1 changed files with 4 additions and 2 deletions
|
@ -583,7 +583,8 @@ gst_caps_append (GstCaps * caps1, GstCaps * caps2)
|
|||
g_return_if_fail (GST_IS_CAPS (caps1));
|
||||
g_return_if_fail (GST_IS_CAPS (caps2));
|
||||
g_return_if_fail (IS_WRITABLE (caps1));
|
||||
g_return_if_fail (IS_WRITABLE (caps2));
|
||||
|
||||
caps2 = gst_caps_make_writable (caps2);
|
||||
|
||||
#ifdef USE_POISONING
|
||||
CAPS_POISON (caps2);
|
||||
|
@ -625,7 +626,8 @@ gst_caps_merge (GstCaps * caps1, GstCaps * caps2)
|
|||
g_return_if_fail (GST_IS_CAPS (caps1));
|
||||
g_return_if_fail (GST_IS_CAPS (caps2));
|
||||
g_return_if_fail (IS_WRITABLE (caps1));
|
||||
g_return_if_fail (IS_WRITABLE (caps2));
|
||||
|
||||
caps2 = gst_caps_make_writable (caps2);
|
||||
|
||||
#ifdef USE_POISONING
|
||||
CAPS_POISON (caps2);
|
||||
|
|
Loading…
Reference in a new issue