data-device: fix crash when a client dies during a drag with an icon
authorAnder Conselvan de Oliveira <ander.conselvan.de.oliveira@intel.com>
Fri, 25 May 2012 07:40:28 +0000 (10:40 +0300)
committerKristian Høgsberg <krh@bitplanet.net>
Sat, 26 May 2012 03:10:01 +0000 (23:10 -0400)
The commit that split wl_input_device into wl_seat and friends changed
erroneously the drag icon destroy listener, causing it to operate into
an invalid pointer to a wl_seat.

src/data-device.c

index 8472da4..a7fc6d2 100644 (file)
@@ -284,7 +284,7 @@ static void
 destroy_data_device_icon(struct wl_listener *listener, void *data)
 {
        struct wl_seat *seat = container_of(listener, struct wl_seat,
-                                           drag_data_source_listener);
+                                           drag_icon_listener);
 
        seat->drag_surface = NULL;
 }