[PATCH weston] compositor: Bail out if prev is NULL in clip_pointer_motion()
Scott Moreau
oreaus at gmail.com
Sat May 12 23:45:12 PDT 2012
We can hit this case if both the preceding calls to
pixman_region32_contains_point() return false.
---
src/compositor.c | 5 ++++-
1 files changed, 4 insertions(+), 1 deletions(-)
diff --git a/src/compositor.c b/src/compositor.c
index e0e0bee..dc878ad 100644
--- a/src/compositor.c
+++ b/src/compositor.c
@@ -1579,7 +1579,10 @@ clip_pointer_motion(struct weston_input_device *device,
old_x, old_y, NULL))
prev = output;
}
-
+
+ if (!prev)
+ return;
+
if (!valid) {
if (x < prev->x)
*fx = wl_fixed_from_int(prev->x);
--
1.7.7.6
More information about the wayland-devel
mailing list