Problem with JavaScript code performing differently than expected.

RESOLVED INCOMPLETE

Status

()

RESOLVED INCOMPLETE
12 years ago
7 years ago

People

(Reporter: pcloches, Unassigned)

Tracking

1.8 Branch
x86
Windows Server 2003
Points:
---

Firefox Tracking Flags

(Not tracked)

Details

Attachments

(1 attachment)

(Reporter)

Description

12 years ago
User-Agent:       Mozilla/5.0 (Windows; U; Windows NT 5.2; en-US; rv:1.8.0.4) Gecko/20060508 Firefox/1.5.0.4
Build Identifier: Mozilla/5.0 (Windows; U; Windows NT 5.2; en-US; rv:1.8.0.4) Gecko/20060508 Firefox/1.5.0.4

JavaScript code gives an error to the javascript console and is not executed properly in 1.5.0.4 Windows, gives same effect but no console error in 1.5.0.1 FreeBSD/Linux.

Error: uncaught exception: [Exception... "Component returned failure code: 0x80004005 (NS_ERROR_FAILURE) [nsIObserverService.removeObserver]"  nsresult: "0x80004005 (NS_ERROR_FAILURE)"  location: "JS frame :: chrome://browser/content/browser.js :: BrowserShutdown :: line 873"  data: no]

If the code is executed in the page itself (update_unit_list), it works properly, however if I execute it via a popup window referencing it by 'opener' it produces the problem. Perhaps there is some reason I cannot do "AJAX"-style things from outside the document?

Reproducible: Always

Steps to Reproduce:
1. Open a page containing attached javascript, and execute opener.update_unit_list(1) from a popup menu.

Actual Results:  
Error message:

Error: uncaught exception: [Exception... "Component returned failure code: 0x80004005 (NS_ERROR_FAILURE) [nsIObserverService.removeObserver]"  nsresult: "0x80004005 (NS_ERROR_FAILURE)"  location: "JS frame :: chrome://browser/content/browser.js :: BrowserShutdown :: line 873"  data: no]

and callback (displ_unit) never called.

Expected Results:  
Should have called displ_unit.

Works properly on IE, though I know its possible I am doing something Wrong and Ie is Wrong in letting me do it :)
(Reporter)

Comment 1

12 years ago
Created attachment 227907 [details]
JavaScript code causing error

If update_unit_list is called from the current document rather than by the popup via opener.update_unit_list, it works as expected.

Comment 2

12 years ago
-> Core: XML (this component includes XMLHttpRequest)

Any chance you could make a reduced testcase?  7kb is a bit big.
Assignee: nobody → xml
Component: General → XML
Product: Firefox → Core
QA Contact: general → ashshbhatt
Version: unspecified → 1.8 Branch

Comment 3

12 years ago
It's a bit disturbing that you're getting errors from browser.js...
(Reporter)

Comment 4

12 years ago
(In reply to comment #3)
> It's a bit disturbing that you're getting errors from browser.js...
> 

I will work on a shorter testcase for tommorow. I am getting errors from browser.js in another portion of the site involving a popup now too.
Assignee: xml → nobody
QA Contact: ashshbhatt → xml

Comment 5

7 years ago
Seems tomorrow never come, closing as incomplete
Status: UNCONFIRMED → RESOLVED
Last Resolved: 7 years ago
Resolution: --- → INCOMPLETE
You need to log in before you can comment on or make changes to this bug.