mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-11-30 05:31:15 +00:00
gl: Fix GError leaks during failures
https://bugzilla.gnome.org/show_bug.cgi?id=755140
This commit is contained in:
parent
b537e98ae7
commit
6944433677
6 changed files with 6 additions and 2 deletions
|
@ -496,6 +496,7 @@ context_error:
|
|||
{
|
||||
GST_ELEMENT_ERROR (mix, RESOURCE, NOT_FOUND, ("%s", error->message),
|
||||
(NULL));
|
||||
g_clear_error (&error);
|
||||
return FALSE;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -587,6 +587,7 @@ context_error:
|
|||
{
|
||||
GST_ELEMENT_ERROR (self, RESOURCE, NOT_FOUND, ("%s", error->message),
|
||||
(NULL));
|
||||
g_clear_error (&error);
|
||||
return FALSE;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -853,6 +853,7 @@ context_error:
|
|||
{
|
||||
GST_ELEMENT_ERROR (src, RESOURCE, NOT_FOUND, ("%s", error->message),
|
||||
(NULL));
|
||||
g_clear_error (&error);
|
||||
if (src->context)
|
||||
gst_object_unref (src->context);
|
||||
src->context = NULL;
|
||||
|
|
|
@ -110,6 +110,7 @@ _mem_create_gl (GstGLContext * context, struct create_data *transfer)
|
|||
|
||||
GST_CAT_ERROR (GST_CAT_GL_BASE_BUFFER, "Failed to create GL buffer: %s",
|
||||
error->message);
|
||||
g_clear_error (&error);
|
||||
}
|
||||
|
||||
void
|
||||
|
|
|
@ -368,6 +368,7 @@ context_error:
|
|||
{
|
||||
GST_ELEMENT_ERROR (trans, RESOURCE, NOT_FOUND, ("%s", error->message),
|
||||
(NULL));
|
||||
g_clear_error (&error);
|
||||
return FALSE;
|
||||
}
|
||||
error:
|
||||
|
|
|
@ -178,7 +178,6 @@ gst_gl_filter_gl_start (GstGLBaseFilter * base_filter)
|
|||
GstGLFilterClass *filter_class = GST_GL_FILTER_GET_CLASS (filter);
|
||||
GstGLContext *context = GST_GL_BASE_FILTER (filter)->context;
|
||||
gint out_width, out_height;
|
||||
GError *error = NULL;
|
||||
|
||||
out_width = GST_VIDEO_INFO_WIDTH (&filter->out_info);
|
||||
out_height = GST_VIDEO_INFO_HEIGHT (&filter->out_info);
|
||||
|
@ -205,7 +204,7 @@ gst_gl_filter_gl_start (GstGLBaseFilter * base_filter)
|
|||
|
||||
context_error:
|
||||
{
|
||||
GST_ELEMENT_ERROR (filter, RESOURCE, NOT_FOUND, ("%s", error->message),
|
||||
GST_ELEMENT_ERROR (filter, RESOURCE, NOT_FOUND, ("Could not generate FBO"),
|
||||
(NULL));
|
||||
return FALSE;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue