ivi-shell: add sanity check in ivi_shell_surface_configure

This should not get called unless there is an ivi_shell_surface.

Signed-off-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
Reviewed-by: Eugen Friedrich <friedrix@gmail.com>
This commit is contained in:
Pekka Paalanen 2016-03-16 15:05:03 +02:00
parent cfb053f27f
commit fd45f60f4e
1 changed files with 5 additions and 1 deletions

View File

@ -108,7 +108,11 @@ ivi_shell_surface_configure(struct weston_surface *surface,
{
struct ivi_shell_surface *ivisurf = get_ivi_shell_surface(surface);
if (surface->width == 0 || surface->height == 0 || ivisurf == NULL)
assert(ivisurf);
if (!ivisurf)
return;
if (surface->width == 0 || surface->height == 0)
return;
if (ivisurf->width != surface->width ||