mirror of
https://github.com/roytam1/palemoon27.git
synced 2026-06-09 09:58:57 +00:00
Don't leak temporary GStreamer caps
This commit is contained in:
@@ -279,7 +279,11 @@ static bool SupportsCaps(GstElementFactory *aFactory, GstCaps *aCaps)
|
||||
continue;
|
||||
}
|
||||
|
||||
if (gst_caps_can_intersect(gst_static_caps_get(&templ->static_caps), aCaps)) {
|
||||
bool supported = gst_caps_can_intersect(caps, aCaps);
|
||||
|
||||
gst_caps_unref(caps);
|
||||
|
||||
if (supported) {
|
||||
return true;
|
||||
}
|
||||
}
|
||||
@@ -307,11 +311,11 @@ bool GStreamerFormatHelper::HaveElementsToProcessCaps(GstCaps* aCaps) {
|
||||
}
|
||||
}
|
||||
|
||||
gst_caps_unref(caps);
|
||||
|
||||
if (!found) {
|
||||
return false;
|
||||
}
|
||||
|
||||
gst_caps_unref(caps);
|
||||
}
|
||||
|
||||
return true;
|
||||
|
||||
Reference in New Issue
Block a user