Closed
Bug 761983
Opened 13 years ago
Closed 13 years ago
JS error when closing the Thunderbird main window in a removeObserver call in search.xml
Categories
(Thunderbird :: Search, defect)
Thunderbird
Search
Tracking
(thunderbird15 fixed)
RESOLVED
FIXED
Thunderbird 16.0
Tracking | Status | |
---|---|---|
thunderbird15 | --- | fixed |
People
(Reporter: florian, Assigned: florian)
References
Details
Attachments
(1 file)
4.29 KB,
patch
|
mconley
:
review+
standard8
:
approval-comm-aurora+
|
Details | Diff | Splinter Review |
JavaScript error: , line 0: uncaught exception: [Exception... "Component returned failure code: 0x80004005 (NS_ERROR_FAILURE) [nsIObserverService.removeObserver]" nsresult: "0x80004005 (NS_ERROR_FAILURE)" location: "JS frame :: chrome://messenger/content/search.xml :: :: line 156" data: no]
We currently have more than one search field in the UI (there's one on the 3 pane mail tab, one on the chat tab, and an additional one per open search tab), we have this error when closing the window once for each search field that wasn't the one of the 3 pane mail tab.
It seems the code causing this error was added in bug 515803 to workaround bug 83635 which is now fixed.
Reverting the changes from bug 515803 lets each search box have its own observer, so that removing it doesn't fail when the destructor is called (as it now seems to be called reliably! :)).
However, when selecting a proposed completion from the autocomplete popup, each observer receives the notification and opens a gloda search tab, which is undesirable. I've added a check on the value of aSubject in the observe method to prevent this.
(CC'ing davida who fixed bug 515803, so that he can tell me if I misunderstood the situation.)
Attachment #630504 -
Flags: review?(mconley)
Comment 2•13 years ago
|
||
Comment on attachment 630504 [details] [diff] [review]
Patch
Review of attachment 630504 [details] [diff] [review]:
-----------------------------------------------------------------
This looks good to me, fixes the issue, and doesn't appear to re-open bug 515803.
Attachment #630504 -
Flags: review?(mconley) → review+
Assignee | ||
Comment 3•13 years ago
|
||
Assignee: nobody → florian
Status: NEW → RESOLVED
Closed: 13 years ago
Resolution: --- → FIXED
Summary: JS error when closing the Thunderbird main window in a removeObserver in search.xml → JS error when closing the Thunderbird main window in a removeObserver call in search.xml
Target Milestone: --- → Thunderbird 16.0
Assignee | ||
Comment 4•13 years ago
|
||
Comment on attachment 630504 [details] [diff] [review]
Patch
[Approval Request Comment]
I would like us to take this on aurora, but it's mostly a cleanup patch, I don't think anything was visibly broken.
Attachment #630504 -
Flags: approval-comm-aurora?
Updated•13 years ago
|
Attachment #630504 -
Flags: approval-comm-aurora? → approval-comm-aurora+
Assignee | ||
Comment 5•13 years ago
|
||
status-thunderbird15:
--- → fixed
You need to log in
before you can comment on or make changes to this bug.
Description
•