mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-01-10 17:35:59 +00:00
msdk: Add return when creating caps fails for VPP
When creating caps fails, the function should return immediately and should not continue to register the plugin. This patch fixes the issue of "gst_mini_object_ref: assertion 'mini_object != NULL' failed" in https://gitlab.freedesktop.org/gstreamer/gstreamer/-/issues/2506 Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4466>
This commit is contained in:
parent
692d4a3a16
commit
ca125bd304
1 changed files with 2 additions and 0 deletions
|
@ -272,6 +272,7 @@ _register_vpp (GstPlugin * plugin,
|
||||||
|
|
||||||
if (!gst_msdkcaps_vpp_create_caps (context, vpp_desc, &sink_caps, &src_caps)) {
|
if (!gst_msdkcaps_vpp_create_caps (context, vpp_desc, &sink_caps, &src_caps)) {
|
||||||
GST_WARNING ("Failed to create caps for VPP");
|
GST_WARNING ("Failed to create caps for VPP");
|
||||||
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!gst_msdkvpp_register (plugin,
|
if (!gst_msdkvpp_register (plugin,
|
||||||
|
@ -373,6 +374,7 @@ _register_vpp (GstPlugin * plugin, GstMsdkContext * context)
|
||||||
|
|
||||||
if (!gst_msdkcaps_vpp_create_caps (context, NULL, &sink_caps, &src_caps)) {
|
if (!gst_msdkcaps_vpp_create_caps (context, NULL, &sink_caps, &src_caps)) {
|
||||||
GST_WARNING ("Failed to create caps for VPP");
|
GST_WARNING ("Failed to create caps for VPP");
|
||||||
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!gst_msdkvpp_register (plugin, context,
|
if (!gst_msdkvpp_register (plugin, context,
|
||||||
|
|
Loading…
Reference in a new issue