L.S.

Here's a little patch to prevent thunar from crashing when dragging
unhandled formats (text, panel plugins, windows from the taskswitcher
applet etc) over its fileview.
For those interested: The call to gtk_drag_get_data ultimately results
in a call to XConvertSelection which generates a BadAtom error.

Steps to reproduce:
* select text somewhere (e.g. in Mousepad)
* drag selected text over the fileview in thunar
* crash

reproducible: always

versions affected:
* trunk
* Xubuntu 9.10
(have not bothered going further back)

best regards,
Karl
diff --git a/thunar/thunar-standard-view.c b/thunar/thunar-standard-view.c
index 83139fc..27802c1 100644
--- a/thunar/thunar-standard-view.c
+++ b/thunar/thunar-standard-view.c
@@ -2857,7 +2857,8 @@ thunar_standard_view_drag_motion (GtkWidget          *view,
       else
         {
           /* request the drag data from the source */
-          gtk_drag_get_data (view, context, target, timestamp);
+          if ( target != GDK_NONE )
+            gtk_drag_get_data (view, context, target, timestamp);
         }

       /* tell Gdk whether we can drop here */


_______________________________________________
Thunar-dev mailing list
Thunar-dev@xfce.org
http://foo-projects.org/mailman/listinfo/thunar-dev

Reply via email to