[mutter] wayland-surface: Ignore bufferless damage
- From: Adel Gadllah <agadllah src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [mutter] wayland-surface: Ignore bufferless damage
- Date: Sun, 27 Apr 2014 14:18:43 +0000 (UTC)
commit c8d0a6692163fc6ce23a60b39fc64693a4209b97
Author: Adel Gadllah <adel gadllah gmail com>
Date: Sun Apr 27 16:18:09 2014 +0200
wayland-surface: Ignore bufferless damage
Instead of letting a buggy client kill us.
src/wayland/meta-wayland-surface.c | 4 ++++
1 files changed, 4 insertions(+), 0 deletions(-)
---
diff --git a/src/wayland/meta-wayland-surface.c b/src/wayland/meta-wayland-surface.c
index 3a8a077..3b1935e 100644
--- a/src/wayland/meta-wayland-surface.c
+++ b/src/wayland/meta-wayland-surface.c
@@ -108,6 +108,10 @@ surface_process_damage (MetaWaylandSurface *surface,
int i, n_rectangles;
cairo_rectangle_int_t buffer_rect;
+ /* Damage without a buffer makes no sense so ignore that, otherwise we would crash */
+ if (!surface->buffer)
+ return;
+
buffer_rect.x = 0;
buffer_rect.y = 0;
buffer_rect.width = cogl_texture_get_width (surface->buffer->texture);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]