After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 539975 - Orca causes Thunderbird 3.0a2pre to crash when deleting an open mail message.
Orca causes Thunderbird 3.0a2pre to crash when deleting an open mail message.
Status: RESOLVED DUPLICATE of bug 540039
Product: orca
Classification: Applications
Component: general
2.23.x
Other Linux
: High major
: 2.24.0
Assigned To: Joanmarie Diggs (IRC: joanie)
Orca Maintainers
Depends on:
Blocks: 404409
 
 
Reported: 2008-06-24 15:41 UTC by Rich Burridge
Modified: 2009-03-10 00:04 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Orca debug log generated whilst testing this problem. (202.95 KB, text/plain)
2008-06-24 15:45 UTC, Rich Burridge
  Details
patch to just stop crashing thunderbird (1.07 KB, patch)
2008-06-24 19:11 UTC, Joanmarie Diggs (IRC: joanie)
none Details | Review

Description Rich Burridge 2008-06-24 15:41:08 UTC
This bug was found whilst testing bug #536451. 

Steps to reproduce:

* Start Orca
* Start Thunderbird
* Tab to the list of mail folders and select a folder.
  I used my Trash folder.
* Tab to the mail header list for that folder, arrow down
  and press Return to open up one of the messages.
* Press Delete to delete that mail message.

After a few moments, Thunderbird will crash.

(Orca debug log to be attached).
Comment 1 Rich Burridge 2008-06-24 15:42:41 UTC
Joanie asked me to assign this one to her.
Comment 2 Rich Burridge 2008-06-24 15:45:50 UTC
Created attachment 113343 [details]
Orca debug log generated whilst testing this problem.

The Delete key press (from the last step) is at line 2745. Last event
processed before we get Tracebacks for lookup errors is:

OBJECT EVENT: document:load-complete                   detail=(0,0)
    app.name='Thunderbird' name='Re: Presto Phase II C-Team checklist' role='document frame' state='enabled focusable focused horizontal opaque sensitive showing visible' relations='node child of'

at line 3088.
Comment 3 David Price 2008-06-24 15:56:02 UTC
Does this crash occur when Orca is not running?
Comment 4 Rich Burridge 2008-06-24 16:08:06 UTC
> Does this crash occur when Orca is not running?

No. 

On IRC this morning, Joanie said:

"... my guess is that we're asking for a bad index".

So she is going to investigate it further before a
Thunderbird bug is submitted, as it might possibly
be something in the Orca Gecko tables code that
needs fixing.

Having said that, even if Orca is requesting a bad
index, Thunderbird shouldn't crash.

More to come...
Comment 5 Joanmarie Diggs (IRC: joanie) 2008-06-24 16:17:34 UTC
Setting the target and upping the priority and severity.  Crashers are bad. :-(
Comment 6 Joanmarie Diggs (IRC: joanie) 2008-06-24 19:11:41 UTC
Created attachment 113362 [details] [review]
patch to just stop crashing thunderbird

The problem is that the live region code is trying to do its thing as a result of the children-changed events.  One of the things it does in the process is queries the document interface of the document frame.  Having done that, it attempts a getAttributes() on that interface.  If you try a getAttributes() on a defunct object, Thunderbird apparently spits up and crashes.  That's a Thunderbird bug, and I'll file one shortly.  In the meantime, we can check for this condition and not trigger the crash.

Note that this patch doesn't cause us to do useful things (like read the title of the message that you are now in having deleted the one you were reading); it merely stops the crash.  The useful things can be new bugs/RFEs. :-)

Already pylinted.  Please test.
Comment 7 Joanmarie Diggs (IRC: joanie) 2008-06-24 19:31:23 UTC
I've opened this Mozilla bug about the crash:
https://bugzilla.mozilla.org/show_bug.cgi?id=441610

I personally don't think we need a GNOME tracking bug as we're going to just not trigger the crash. :-)  I've also blocked our Mozilla tracking bug https://bugzilla.mozilla.org/show_bug.cgi?id=374212 for the purpose of tracking.
Comment 8 David Price 2008-06-24 20:39:46 UTC
This is successful at stopping the crash.  

However, there is a side effect that should be thought about.  With this patch in place, the message is deleted from the message list, but the user is not notified that the message has been deleted from the message list and a new message has focus.  In addition, the message window remains open, which could lead the user to believe that pressing the delete key resulted in no action being taken. Since the next message in my mailbox could be deleted, I switched back to the message view of the "deleted message", and pressed delete again.  And, yes, the next message in the message list was deleted.  I can foresee a frustrated user hitting the delete key repeatedly and wiping out all of the messages in the open mailbox.

I would suggest that either the problem of not speaking the newly focused message in the list needs to be addressed before this patch is applied to svn trunk or, when this patch is applied to svn trunk, a message be sent out to the mailing list describing this danger and a similar message be posted on the wiki.  Just my two cents...
Comment 9 Joanmarie Diggs (IRC: joanie) 2008-06-24 20:49:35 UTC
Yeah, I'm not sure which is worse:  Crashing all of Thunderbird when you delete a message, or deleting a message and not realizing it and ultimately blowing away all of your messages as a result.  So....

I've opened a bug on the need to speak the newly focused message in this case:
bug 540039.
Comment 10 Joanmarie Diggs (IRC: joanie) 2008-06-24 20:53:31 UTC
Heh.  Marco just marked the crasher bug as FIXED.  I assume it will be in the nightly Thunderbird build tomorrow.  So whether we check this patch in or not, we're in the same boat.
Comment 11 David Price 2008-06-24 21:17:33 UTC
I think we will need to see what happens with the Mozilla bug fixed. I believe the expected behavior is that, when in a message view window, pressing delete will close the message and delete it from the message list. Hopefully, with Orca's focus moving back into the message list, the newly focused message will be spoken.
Comment 12 Joanmarie Diggs (IRC: joanie) 2008-06-24 21:28:19 UTC
Well, apparently we're now waiting for things to land:

--- Comment #5 from Marco Zehe (:MarcoZ) <marco.zehe@googlemail.com>  2008-06-24 13:58:33 PDT ---
Hi Joanie,

for the time being and for your own builds, these new style patches get applied
using patch -p1, not patch -p0 as CVS patches do. But if you like, you're
welcome to use the patch in a build of yours and continue your work with that
build until we hopefully get this landed on the 1.9.0.x branch, which is what
Thunderbird 3.0a2pre is currently using.
---------------

Regardless, David, unless I'm missing something focus isn't going to go back to the message list.  Without Orca, if I delete an open message, the message is deleted and a new one appears in its place.  All my patch does is not ask for the attributes of an object that no longer exists.

I'll update tbird and apply Marco's patch and see...
Comment 13 Rich Burridge 2008-06-24 21:57:35 UTC
> ... unless I'm missing something focus isn't going to go back to
> the message list.  Without Orca, if I delete an open message, the message is
> deleted and a new one appears in its place.

Yup. I can confirm this.
Comment 14 Joanmarie Diggs (IRC: joanie) 2008-06-25 18:12:19 UTC
Because the fix for this bug is needed to test the patch for bug 540039 (which causes the new message to be presented after deletion), I've combined the patch for this bug with the current patch in bug 540039.  Easier to just have one patch and one bug.  Closing this one as a dup.

*** This bug has been marked as a duplicate of 540039 ***