wayland: set the interface vfuncs when declaring the keyboard interface

Otherwise the NULL vtable would be accessed when trying to release the keyboard.

https://bugzilla.gnome.org/show_bug.cgi?id=733563
This commit is contained in:
Carlos Garnacho 2014-07-22 00:27:39 +02:00
parent e49bbe2ed8
commit dfe1c106f2

View File

@ -549,7 +549,7 @@ meta_wayland_keyboard_create_new_resource (MetaWaylandKeyboard *keyboard,
cr = wl_resource_create (client, &wl_keyboard_interface,
MIN (META_WL_KEYBOARD_VERSION, wl_resource_get_version (seat_resource)), id);
wl_resource_set_implementation (cr, NULL, keyboard, unbind_resource);
wl_resource_set_implementation (cr, &keyboard_interface, keyboard, unbind_resource);
wl_list_insert (&keyboard->resource_list, wl_resource_get_link (cr));
wl_keyboard_send_keymap (cr,