mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-11-30 05:31:15 +00:00
vksink: Fix GError memory leak
https://bugzilla.gnome.org/show_bug.cgi?id=762842
This commit is contained in:
parent
14521dc774
commit
e821582c13
1 changed files with 2 additions and 0 deletions
|
@ -256,6 +256,7 @@ gst_vulkan_sink_change_state (GstElement * element, GstStateChange transition)
|
||||||
gst_vulkan_instance_create_device (vk_sink->instance, &error))) {
|
gst_vulkan_instance_create_device (vk_sink->instance, &error))) {
|
||||||
GST_ELEMENT_ERROR (vk_sink, RESOURCE, NOT_FOUND,
|
GST_ELEMENT_ERROR (vk_sink, RESOURCE, NOT_FOUND,
|
||||||
("Failed to create vulkan device"), ("%s", error->message));
|
("Failed to create vulkan device"), ("%s", error->message));
|
||||||
|
g_clear_error (&error);
|
||||||
return GST_STATE_CHANGE_FAILURE;
|
return GST_STATE_CHANGE_FAILURE;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -269,6 +270,7 @@ gst_vulkan_sink_change_state (GstElement * element, GstStateChange transition)
|
||||||
if (!gst_vulkan_window_open (vk_sink->window, &error)) {
|
if (!gst_vulkan_window_open (vk_sink->window, &error)) {
|
||||||
GST_ELEMENT_ERROR (vk_sink, RESOURCE, NOT_FOUND,
|
GST_ELEMENT_ERROR (vk_sink, RESOURCE, NOT_FOUND,
|
||||||
("Failed to open window"), ("%s", error->message));
|
("Failed to open window"), ("%s", error->message));
|
||||||
|
g_clear_error (&error);
|
||||||
return GST_STATE_CHANGE_FAILURE;
|
return GST_STATE_CHANGE_FAILURE;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue