Merge branch 'fix-x11-cursor-crash' into 'master'

x11: Only update cursors if we have any

Closes #2308

See merge request GNOME/gtk!1249
This commit is contained in:
Matthias Clasen 2019-12-13 20:02:43 +00:00
commit 9a5ec33d61

View File

@ -305,6 +305,9 @@ gdk_x11_display_set_cursor_theme (GdkDisplay *display,
if (size > 0)
XcursorSetDefaultSize (xdisplay, size);
if (GDK_X11_DISPLAY (display)->cursors == NULL)
return;
g_hash_table_iter_init (&iter, GDK_X11_DISPLAY (display)->cursors);
while (g_hash_table_iter_next (&iter, &cursor, &xcursor))
{