mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-11-29 13:11:06 +00:00
va: don't use GST_ELEMENT_WARNING in set_context() vmethod
Since bins can set the context of their children elements, the set_context() vmethod shouldn't call bus messages post methods, since it locks the parent object, the bin, which might be already locked, leading to a deadlock. Fixes: #3706 Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/7379>
This commit is contained in:
parent
bfcd23db61
commit
85fee9738e
4 changed files with 4 additions and 8 deletions
|
@ -658,8 +658,7 @@ gst_va_base_dec_set_context (GstElement * element, GstContext * context)
|
||||||
if (!ret
|
if (!ret
|
||||||
|| (old_display && new_display && old_display != new_display
|
|| (old_display && new_display && old_display != new_display
|
||||||
&& base->decoder)) {
|
&& base->decoder)) {
|
||||||
GST_ELEMENT_WARNING (base, RESOURCE, BUSY,
|
GST_WARNING_OBJECT (base, "Can't replace VA display while operating");
|
||||||
("Can't replace VA display while operating"), (NULL));
|
|
||||||
}
|
}
|
||||||
|
|
||||||
gst_clear_object (&old_display);
|
gst_clear_object (&old_display);
|
||||||
|
|
|
@ -850,8 +850,7 @@ gst_va_base_enc_set_context (GstElement * element, GstContext * context)
|
||||||
|
|
||||||
if (!ret || (old_display && new_display && old_display != new_display
|
if (!ret || (old_display && new_display && old_display != new_display
|
||||||
&& base->encoder)) {
|
&& base->encoder)) {
|
||||||
GST_ELEMENT_WARNING (element, RESOURCE, BUSY,
|
GST_WARNING_OBJECT (element, "Can't replace VA display while operating");
|
||||||
("Can't replace VA display while operating"), (NULL));
|
|
||||||
}
|
}
|
||||||
|
|
||||||
gst_clear_object (&old_display);
|
gst_clear_object (&old_display);
|
||||||
|
|
|
@ -610,8 +610,7 @@ gst_va_base_transform_set_context (GstElement * element, GstContext * context)
|
||||||
if (!ret
|
if (!ret
|
||||||
|| (old_display && new_display && old_display != new_display
|
|| (old_display && new_display && old_display != new_display
|
||||||
&& self->filter)) {
|
&& self->filter)) {
|
||||||
GST_ELEMENT_WARNING (element, RESOURCE, BUSY,
|
GST_WARNING_OBJECT (element, "Can't replace VA display while operating");
|
||||||
("Can't replace VA display while operating"), (NULL));
|
|
||||||
}
|
}
|
||||||
|
|
||||||
gst_clear_object (&old_display);
|
gst_clear_object (&old_display);
|
||||||
|
|
|
@ -420,8 +420,7 @@ gst_va_compositor_set_context (GstElement * element, GstContext * context)
|
||||||
if (!ret
|
if (!ret
|
||||||
|| (old_display && new_display && old_display != new_display
|
|| (old_display && new_display && old_display != new_display
|
||||||
&& self->filter)) {
|
&& self->filter)) {
|
||||||
GST_ELEMENT_WARNING (element, RESOURCE, BUSY,
|
GST_WARNING_OBJECT (element, "Can't replace VA display while operating");
|
||||||
("Can't replace VA display while operating"), (NULL));
|
|
||||||
}
|
}
|
||||||
|
|
||||||
gst_clear_object (&old_display);
|
gst_clear_object (&old_display);
|
||||||
|
|
Loading…
Reference in a new issue