[patch] color picker crash


I just found a bug in color picker (grab release problem).

Here is a patch to fix it.

Index: gdk/x11/gdkimage-x11.c
RCS file: /cvs/gnome/gtk+/gdk/x11/gdkimage-x11.c,v
retrieving revision 1.43
diff -u -r1.43 gdkimage-x11.c
--- gdk/x11/gdkimage-x11.c	25 Apr 2002 22:29:12 -0000	1.43
+++ gdk/x11/gdkimage-x11.c	29 Apr 2002 16:41:07 -0000
@@ -652,7 +652,7 @@
   if (have_grab)
       gdk_x11_display_ungrab (gdk_drawable_get_display (drawable));
-      XFlush (GDK_DRAWABLE_XDISPLAY (drawable));
+      XFlush (gdk_x11_drawable_get_xdisplay (drawable));
       have_grab = FALSE;

The problem is that GDK_DRAWABLE_XDISPLAY expect a GdkDrawable as oppose
to gdk_x11_drawable_get_xdisplay which can deal with GdkDrawable and
So I guess an other patch would be the change GDK_DRAWABLE_XDISPLAY
itself to be gdk_x11_drawable_get_xdisplay.

What is best ?

If the patch is ok, can I commit ?

	Best Regards,

 Erwann Chénedé, Sun Microsystems, Ireland
 Phone  : +353 1 8199031         xt: 19031
[ I speak for myself, not for my employer ]

[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]