GNOME Bugzilla – Bug 372545
crash in Epiphany Web Bookmarks: clicking toolbar or menu...
Last modified: 2014-08-15 14:31:45 UTC
Version: 2.17.2 What were you doing when the application crashed? clicking toolbar or menu, I'm not sure. Distribution: Debian 4.0 Gnome Release: 2.17.2 2006-11-07 (GARNOME) BugBuddy Version: 2.16.0 Memory status: size: 119734272 vsize: 0 resident: 119734272 share: 0 rss: 40034304 rss_rlim: 0 CPU usage: start_time: 1163004697 rtime: 0 utime: 586 stime: 0 cutime:559 cstime: 0 timeout: 27 it_real_value: 0 frequency: 0 Backtrace was generated from '/home/boat/garnome/bin/epiphany' Using host libthread_db library "/lib/tls/i686/cmov/libthread_db.so.1". [Thread debugging using libthread_db enabled] [New Thread -1229498688 (LWP 3342)] [New Thread -1300845648 (LWP 3356)] [New Thread -1312818256 (LWP 3355)] [New Thread -1284060240 (LWP 3354)] [New Thread -1275667536 (LWP 3352)] [New Thread -1292452944 (LWP 3351)] [New Thread -1257505872 (LWP 3344)] [New Thread -1237058640 (LWP 3343)] 0xb7fe1410 in __kernel_vsyscall ()
+ Trace 84417
Thread 1 (Thread -1229498688 (LWP 3342))
Thanks for the bug report. This is a crash in libgail; re-assigning.
Problem is not the assert, but rather that when menu_item_remove_gtk() is getting called, for some reason the removed widget is not turning up in gail_container->children when the "remove" gsignal is handled, i.e this call index = g_list_index (gail_container->children, widget); in gailsubmenuitem.c is failing.
*** Bug 372710 has been marked as a duplicate of this bug. ***
add GNOME-a11y-bugs-EXT@sun.com to cc list
*** Bug 382971 has been marked as a duplicate of this bug. ***
*** Bug 382975 has been marked as a duplicate of this bug. ***
confirming
*** Bug 390482 has been marked as a duplicate of this bug. ***
*** Bug 391279 has been marked as a duplicate of this bug. ***
Note that in the first stack trace, around frame #24, update_node seems to be recursing. The name of a calling function (do_updates_idle) suggests that this is happenning in an idle handler. I wonder if the events are being emitted after the menu items have already been removed from the parent container? This would be a serious problem for gail, as it requires that such events be synchronous in order to fulfill the ATK API (i.e. the children must be accessible when firing the 'removed' event).
When applications call gtk_menu_shell_insert to insert a menu item, it will not emit "add" signal (as gtk_container_add does), so gail gets no chance to add the menu item to the gail_container.
Application calls gtk_menu_shell_insert to add menu_item to menu. This function will not emit "add" signal. (gtk_container_add will emit this signal.) The problem is GtkMenuShell overloads GtkContainer's add function(which will be called first when "add" signal emits) with gtk_menu_shell_add, this function will call gtk_menu_shell_insert finally. So we can not emit the "add" signal in gtk_menu_shell_insert. So I cannot find a good way to emit "add" signal...
*** Bug 395131 has been marked as a duplicate of this bug. ***
Created attachment 80013 [details] [review] proposed patch to fix crash, but still need more work to receive the "add" signal
This patch can fix crash. Further work is still needed to receive the "add" signal.
*** Bug 392957 has been marked as a duplicate of this bug. ***
Created attachment 80295 [details] [review] patch of gtk part
*** Bug 375870 has been marked as a duplicate of this bug. ***
Hi Matthias, Can you help me to review the gtk part of patch? The patch emit "add" by calling gtk_container_add in gtk_menu_shell_real_insert. Since emit this signal will cause GTK_CONTAINER->add be called (which will call gtk_menu_shell_real_insert finally), I add a check here to prevent emiting the signal twice or more.
Li, I suggest you to create a gtk bug and make this bug depend on it. Thus we can have more gtk developers to look at your patch.
*** Bug 400576 has been marked as a duplicate of this bug. ***
*** Bug 387907 has been marked as a duplicate of this bug. ***
Review of attachment 80295 [details] [review]: This patch is a pretty bad way to accomplish the desired effect. We have an "insert" signal on GtkMenuShell now that is a reliable way of determining menu items are added to a menu. Can that be used instead?
Created attachment 213426 [details] [review] GtkMenuItemAccessible: use "insert" signal Use the "insert" rather than the "add" signal to reliably detect additions of menu items.
Hi Ryan, Any reason your patch has not been applied yet?
Attachment 213426 [details] pushed as 49ccb23 - GtkMenuItemAccessible: use "insert" signal