Re: [gtk-list] Bug: push_visual/push_colormap bug related to styles on certain machines.




Hi,
With following patch, at least warning message disappeared.
But I cannot be sure this is correct.

--- gtkstyle.c.orig	Wed Jun  2 10:20:53 1999
+++ gtkstyle.c	Wed Jun  2 10:23:21 1999
@@ -527,6 +527,11 @@
     gtk_style_ref (new_style);
   
   new_style->attach_count++;
+  if (style != new_style) 
+    {
+      gtk_style_unref (style);
+      gtk_style_ref (new_style);
+    }
   
   return new_style;
 }

On Tue, 25 May 1999, Todd Dukes wrote:

> I have included a short example below.
> 
> I see this on Solaris, but it runs with no complaints on RH Linux 6.0.
> 
> I am using glib/gtk 1.2.3 and imlib 1.9.4 I was not able to determine
> if it might be an imlib problem.
> 
> The example program below displays a window for a short while before 
> entering the main loop. The purpose of this was to display a splash
> screen with a pixmap and a status bar in it to let the user know how
> initialization was going. Since this code was not needed to reproduce
> the bug, it has been removed. After displaying and hiding the splash
> screen a window containing a ctree is opened. Clicking the right mouse
> button opens a popup menu.
> 
> You should be able to use the command at the top of the source file
> to compile the example. In the current state, there are no problems. 
> If you uncomment the #define WITH_PIXMAP line ( around line 12 in the
> example ) you may see the following.
> 
> Gtk-CRITICAL **: file gtkstyle.c: line 683 (gtk_style_destroy):
> assertion `style->attach_count == 0' failed.
> 
> Gtk-CRITICAL **: file gtkstyle.c: line 575 (gtk_style_unref): assertion
> `style->ref_count > 0' failed.
> 
> Gtk-CRITICAL **: file gtkstyle.c: line 575 (gtk_style_unref): assertion
> `style->ref_count > 0' failed.
> 
> Gtk-CRITICAL **: file gtkstyle.c: line 575 (gtk_style_unref): assertion
> `style->ref_count > 0' failed.
> 
> Gtk-CRITICAL **: file gtkstyle.c: line 575 (gtk_style_unref): assertion
> `style->ref_count > 0' failed.
> 
> 
> Any help would be appreciated.
> 
> thanks,
> Todd.
> 
> 
> -- 
>    | Todd Dukes                      E-MAIL:  tdukes@ibmoto.com |
>    | Motorola Somerset                  Phone:   (512) 424-8008 |
>    | 6200 Bridgepoint Parkway Building #4 MS OE70               |
>    | Austin, Texas 78730                                        |



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