Re: [g-a-devel]Gail Crashes


The problem here is that the GtkWidget pointer we hold still has a reference in it, but the actual GtkWidget structure it points to is gone. So, when we call gtk_widget_get_accessible, things go wrong.

If we ref the widget, is that enough? WE don't want to prevent the widget from being destroyed, we just want to be notified when it is destroyed.

Maybe weakrefs are the answer...


At 01:43 PM 3/30/2002 +0000, Bill Haneman wrote:
Marc Mulcahy wrote:


> 1. We cache the object which had the focus before the menubar got it so we
> can fake a focus event to it after the menu bar is deactivated.  And, if
> that object happens to be gone, as a result of clicking the "exit
> application" menu item for example, we understandably blow up all the way
> through the stack.


It strikes me that this, since we are sending events asynchronously,
is going to happen sometimes (i.e. focus event received for dead object)
no matter what.  It's not clear to me that this needs to be a fatal
if it is, then we have a problem.  So I think the right approach is to
recover from this condition sanely when it occurs...

In other words recipients of events should not blow up if the "source"
object is gone.  Note that the Accessibility_Accessible object should
not have been destroyed since the event carries a reference which is
decremented after receipt of the event, so the issue is calling API
on the "defunct" object.  It seems that the client needs to either check
state of the object to see if it's "defunct" or not (which means we
must report this state correctly), or else it needs to gracefully
recover from the CORBA errors which occur when calling API on a defunct

Gnome-accessibility-devel mailing list
Gnome-accessibility-devel gnome org

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