diff options
author | Michael Olbrich <m.olbrich@pengutronix.de> | 2023-02-07 10:23:03 +0100 |
---|---|---|
committer | Michael Olbrich <m.olbrich@pengutronix.de> | 2023-02-07 15:43:18 +0100 |
commit | f7609553a926881786f6ca4f60ba8d5ad6b5b152 (patch) | |
tree | e473d3fbf24a7ade6d6ae8d3f3e1c247b4ed9812 /ivi-shell | |
parent | 2c96bdbdbf51ff6e205f4988fe437355bddb969e (diff) | |
download | weston-f7609553a926881786f6ca4f60ba8d5ad6b5b152.tar.gz |
ivi-shell: remove some unnecessary checks
Both functions are callbacks that are added when the ivi_shell_surface is
created and removed when it is destroyed, so get_ivi_shell_surface() will never
return NULL here.
Signed-off-by: Michael Olbrich <m.olbrich@pengutronix.de>
Diffstat (limited to 'ivi-shell')
-rw-r--r-- | ivi-shell/ivi-shell.c | 7 |
1 files changed, 0 insertions, 7 deletions
diff --git a/ivi-shell/ivi-shell.c b/ivi-shell/ivi-shell.c index 4a56584e..3dc7337a 100644 --- a/ivi-shell/ivi-shell.c +++ b/ivi-shell/ivi-shell.c @@ -121,10 +121,6 @@ ivi_shell_surface_committed(struct weston_surface *surface, { struct ivi_shell_surface *ivisurf = get_ivi_shell_surface(surface); - assert(ivisurf); - if (!ivisurf) - return; - if (surface->width == 0 || surface->height == 0) return; @@ -145,9 +141,6 @@ ivi_shell_surface_get_label(struct weston_surface *surface, { struct ivi_shell_surface *shell_surf = get_ivi_shell_surface(surface); - if (!shell_surf) - return snprintf(buf, len, "unidentified window in ivi-shell"); - return snprintf(buf, len, "ivi-surface %#x", shell_surf->id_surface); } |