summaryrefslogtreecommitdiff
path: root/gdk/wayland
diff options
context:
space:
mode:
authorMatthias Clasen <mclasen@redhat.com>2013-03-26 21:27:21 -0400
committerMatthias Clasen <mclasen@redhat.com>2013-03-26 21:27:21 -0400
commit93e5d83a9da46a2c9a3b95a7a6f1296ecd49fdc9 (patch)
tree718d81ef42a1a27bb30f6d50e021ac9922da9a68 /gdk/wayland
parent7069f6a251bae6bf549d6ea7c9e43bd6d851c325 (diff)
downloadgtk+-93e5d83a9da46a2c9a3b95a7a6f1296ecd49fdc9.tar.gz
Don't decrement the init_ref_count towards -infinity
Once we are at zero, initialization is done.
Diffstat (limited to 'gdk/wayland')
-rw-r--r--gdk/wayland/gdkscreen-wayland.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/gdk/wayland/gdkscreen-wayland.c b/gdk/wayland/gdkscreen-wayland.c
index 5d1768882a..1acc81aa3d 100644
--- a/gdk/wayland/gdkscreen-wayland.c
+++ b/gdk/wayland/gdkscreen-wayland.c
@@ -872,8 +872,10 @@ output_handle_geometry(void *data,
monitor->output_name = g_strdup (model);
/* Once we have the geometry event we know we have all events
- * from the wl_output and need no further init roundtrips. */
- display->init_ref_count--;
+ * from the wl_output and need no further init roundtrips.
+ */
+ if (display->init_ref_count > 0)
+ display->init_ref_count--;
}
static void