compositor-drm: Check surface's outputs when assigning overlays

Check if the output passed to drm_output_prepare_overlay_surface() does
actually contain the surface and fail if it doesn't. Also fail if a
surface spans multiple outputs since clearing the damage will cause the
portion that is not in an overlay to not be updated at all.
This commit is contained in:
Ander Conselvan de Oliveira
2012-06-26 17:09:12 +03:00
committed by Kristian Høgsberg
parent 57e0ce1d2a
commit d450b1901f
+3
View File
@@ -530,6 +530,9 @@ drm_output_prepare_overlay_surface(struct weston_output *output_base,
if (c->sprites_are_broken) if (c->sprites_are_broken)
return -1; return -1;
if (es->output_mask != (1u << output_base->id))
return -1;
if (surface_is_primary(ec, es)) if (surface_is_primary(ec, es))
return -1; return -1;