summaryrefslogtreecommitdiffstats
path: root/wayland-system-compositor.c
diff options
context:
space:
mode:
authorKristian Høgsberg <krh@redhat.com>2009-02-10 18:30:14 -0500
committerKristian Høgsberg <krh@redhat.com>2009-02-10 18:30:14 -0500
commit1febe0108461a067bc4839ad74c8415644e785b6 (patch)
tree381f29b6ca50dec7b69ec672c0b16036a5af24a1 /wayland-system-compositor.c
parent6c9c8f8923926bf0bf270c0ecf21eae8371d4778 (diff)
downloadwayland-1febe0108461a067bc4839ad74c8415644e785b6.tar.gz
wayland-1febe0108461a067bc4839ad74c8415644e785b6.tar.xz
wayland-1febe0108461a067bc4839ad74c8415644e785b6.zip
Don't crash when there's no primary surface.
Diffstat (limited to 'wayland-system-compositor.c')
-rw-r--r--wayland-system-compositor.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/wayland-system-compositor.c b/wayland-system-compositor.c
index a0ab5f9..384b86d 100644
--- a/wayland-system-compositor.c
+++ b/wayland-system-compositor.c
@@ -1014,7 +1014,7 @@ notify_key(struct wlsc_input_device *device,
case KEY_LEFTMETA | META_DOWN:
case KEY_RIGHTMETA | META_DOWN:
ec->meta_state = state ? META_DOWN : 0;
- if (state == 0) {
+ if (state == 0 && ec->primary != NULL) {
ec->primary->target.z = 0;
wl_list_remove(&ec->primary->animate.link);
wl_list_insert(&ec->animate_list,