mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-11-20 08:41:07 +00:00
ximagesrc: Fix NULL pointer dereference when allocation of the ximage fails
This commit is contained in:
parent
8b2a6a8c74
commit
34d42e4ea3
1 changed files with 2 additions and 1 deletions
|
@ -389,7 +389,8 @@ gst_ximage_src_ximage_get (GstXImageSrc * ximagesrc)
|
||||||
(BufferReturnFunc) (gst_ximage_src_return_buf));
|
(BufferReturnFunc) (gst_ximage_src_return_buf));
|
||||||
if (ximage == NULL) {
|
if (ximage == NULL) {
|
||||||
GST_ELEMENT_ERROR (ximagesrc, RESOURCE, WRITE, (NULL),
|
GST_ELEMENT_ERROR (ximagesrc, RESOURCE, WRITE, (NULL),
|
||||||
("could not create a %dx%d ximage", ximage->width, ximage->height));
|
("could not create a %dx%d ximage", ximagesrc->width,
|
||||||
|
ximagesrc->height));
|
||||||
g_mutex_unlock (ximagesrc->x_lock);
|
g_mutex_unlock (ximagesrc->x_lock);
|
||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue