[mutter] compositor: Fix crash when adding a window with an opaque region



commit 1f905bd0e2562d36f1d3e458907f327605b3a10c
Author: Jasper St. Pierre <jstpierre mecheye net>
Date:   Wed Mar 13 22:34:20 2013 -0400

    compositor: Fix crash when adding a window with an opaque region
    
    If _NET_WM_OPAQUE_REGION is set when the window is first mapped, the
    initial load_properties will happen before the window actor is created,
    and we'll have a call to meta_compositor_window_shape_changed. Just
    fizzle this call out instead of doing anything fancy, as we'll pick
    up the opaque region when the window actor is eventually created.
    
    https://bugzilla.gnome.org/show_bug.cgi?id=695813

 src/compositor/compositor.c |    3 +++
 1 files changed, 3 insertions(+), 0 deletions(-)
---
diff --git a/src/compositor/compositor.c b/src/compositor/compositor.c
index fcc9a00..d6aa536 100644
--- a/src/compositor/compositor.c
+++ b/src/compositor/compositor.c
@@ -784,6 +784,9 @@ meta_compositor_window_shape_changed (MetaCompositor *compositor,
 {
   MetaWindowActor *window_actor;
   window_actor = META_WINDOW_ACTOR (meta_window_get_compositor_private (window));
+  if (!window_actor)
+    return;
+
   meta_window_actor_update_shape (window_actor);
 }
 


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]