Re: dragging bug caused by fix for GtkInvisible style attach leak
- From: Owen Taylor <otaylor redhat com>
- To: gtk-devel-list gnome org
- Subject: Re: dragging bug caused by fix for GtkInvisible style attach leak
- Date: 02 Jan 2001 12:25:25 -0500
Alexander Larsson <alla lysator liu se> writes:
> On 30 Dec 2000, Havoc Pennington wrote:
>
> >
> > Hi,
> >
> > OK, I just applied this patch, seems to fix the crash I was seeing
> > with this (selections in the text widget).
> >
> > Index: gdk/x11/gdkwindow-x11.c
> > ===================================================================
> > RCS file: /cvs/gnome/gtk+/gdk/x11/gdkwindow-x11.c,v
> > retrieving revision 1.100
> > diff -u -u -r1.100 gdkwindow-x11.c
> > --- gdk/x11/gdkwindow-x11.c 2000/12/15 01:46:40 1.100
> > +++ gdk/x11/gdkwindow-x11.c 2000/12/30 15:44:25
> > @@ -482,7 +482,8 @@
> > private->depth = 0;
> > class = InputOnly;
> > private->input_only = TRUE;
> > - draw_impl->colormap = NULL;
> > + draw_impl->colormap = gdk_colormap_get_system ();
> > + gdk_colormap_ref (draw_impl->colormap);
> > }
> >
>
> Here is the corresponding STABLE fix. Can I commit this?
OK, sure, go ahead. (This change is not quite right in some
theoretical sense, but almost certainly the simple way to
handle things in practice.)
> Index: gdkwindow.c
> ===================================================================
> RCS file: /cvs/gnome/gtk+/gdk/gdkwindow.c,v
> retrieving revision 1.80.2.9
> diff -u -p -r1.80.2.9 gdkwindow.c
> --- gdkwindow.c 2000/01/27 21:10:44 1.80.2.9
> +++ gdkwindow.c 2001/01/02 10:11:58
> @@ -401,7 +401,7 @@ gdk_window_new (GdkWindow *parent,
> {
> depth = 0;
> class = InputOnly;
> - private->colormap = NULL;
> + private->colormap = gdk_colormap_get_system ();
Hmm, like Havoc's patch, I think you need the ref here. (Looking
at this, there are some problems with refcounting, colormaps
and drawables in head, but for stable, things should be simple.)
Regards,
Owen
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]