Re: gtkrbtree core dump

2012-10-01 Thread Emmanuele Bassi
On 30 September 2012 17:37, Roger Davis r...@soest.hawaii.edu wrote:

 Hello all,

 I am encountering an infrequent but serious bug which is causing core dumps
 in one or more of my GTK3+ apps. At the time my code dumps core I see the
 message

 Gtk:ERROR:gtkrbtree.c:465:_gtk_rbtree_insert_after: assertion failed:
 (_gtk_rbtree_is_nil (tree-root))

the RBTree is a private data structure used internally by gtk+.

use gdb and gather a stack trace of the assertion failure. you'll see
the call stack, so you'll be able to figure out what's calling that
function with a empty RBTree.

ciao,
 Emmanuele.

-- 
W: http://www.emmanuelebassi.name
B: http://blogs.gnome.org/ebassi/
___
gtk-app-devel-list mailing list
gtk-app-devel-list@gnome.org
https://mail.gnome.org/mailman/listinfo/gtk-app-devel-list


Re: gtkrbtree core dump

2012-10-01 Thread Roger Davis

Hello Emmanuele,

Thank you for your suggestions!


the RBTree is a private data structure used internally by gtk+.


Some people here have suggested that this rbtree code is used by 
GtkTreeView objects, so I have been focusing my attention on parts of my 
code which might be referencing such things indirectly. I do not use any 
GtkTreeView objects directly in my code. Are you saying that this rbtree 
code is also used by other parts of GTK that have nothing to do with 
GtkTreeView objects?



use gdb and gather a stack trace of the assertion failure. you'll see
the call stack, so you'll be able to figure out what's calling that
function with a empty RBTree.



I am hoping to do this, unfortunately these failures are pretty rare and I 
cannot cause one on demand. My reading of the code, however, indicates 
that the g_assert fails because tree-root is *not* nil:


g_assert (_gtk_rbtree_is_nil (tree-root));

I am trying to understand what happens inside g_assert. The glib 
documentation says it should dump core inside the assert *unless* the 
g_assert macro has been turned off, and then implies that the macro is 
probably turned off in a final code release, which should mean that the 
core dump is actually happening later on, perhaps in a very different 
stack backtrace. Do you know anything about this? Is there a way I can 
examine the code build configuration to determine whether the assert core 
dump is enabled or disabled? I suppose that ideally I would like the core 
dump to occur in the assertion so I can better locate the source of the 
failure.


Thanks!

Roger

___
gtk-app-devel-list mailing list
gtk-app-devel-list@gnome.org
https://mail.gnome.org/mailman/listinfo/gtk-app-devel-list