forked from enlightenment/efl
evas-wayland-shm: Do not dereference a potentially freed pointer
Coverity reports that _evas_dmabuf_buffer_init function here can potentially free the surface that was passed into it. If that happens, we should not be calling the _fallback function with surface as the parameter as that will directly dereference the freed pointer. Fixes Coverity CID1381707 @fix Signed-off-by: Chris Michael <cp.michael@samsung.com>
This commit is contained in:
parent
de1e18ef7d
commit
fd79e32dbd
|
@ -519,7 +519,7 @@ _evas_dmabuf_surface_reconfigure(Surface *s, int w, int h, uint32_t flags EINA_U
|
|||
buf = _evas_dmabuf_buffer_init(surface, w, h);
|
||||
if (!buf)
|
||||
{
|
||||
_fallback(surface, w, h);
|
||||
if (surface) _fallback(surface, w, h);
|
||||
s->surf.dmabuf = NULL;
|
||||
return;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue