window.open() for a given window fails the second time.

RESOLVED FIXED in Camino0.9

Status

P2
major
RESOLVED FIXED
14 years ago
14 years ago

People

(Reporter: sfraser_bugs, Assigned: sfraser_bugs)

Tracking

({regression})

unspecified
Camino0.9
PowerPC
macOS
regression

Details

Attachments

(1 attachment)

(Assignee)

Description

14 years ago
When a page uses window.open() to open a window, like:

window.open('http://www.smfr.org', 'window_name', 'scrollbars=0,resizable=no')

if you close the resulting window and click the button again, no window is opened.

My guess is that the nsWindowWatcher thinks the window is still around, so
refuses to open a 2nd one.
(Assignee)

Comment 1

14 years ago
Created attachment 190355 [details]
Testcase
(Assignee)

Comment 2

14 years ago
I debugged this. The code path between the working first click, and the broken
second click on the button diverges in nsJSEventListener::HandleEvent() on the

if (JS_TypeOfValue(cx, funval) != JSTYPE_FUNCTION)

test. The first time, funval is something reasonable. The second time, it's
0x80000001 so we bail.

I've no idea why this is broken. When the popup is closed, we're calling
nsWindowWatcher::RemoveWindow(), so it's not a nsWindowWatcher issue.
(Assignee)

Comment 3

14 years ago
Possibly a recent regression, could break some sites.
Severity: normal → major
Status: NEW → ASSIGNED
Priority: -- → P2
Target Milestone: --- → Camino0.9
(Assignee)

Updated

14 years ago
Keywords: regression
The patch in bug 301316 should fix this.
Depends on: 301316
Should probably retest in tomorrow's builds before resolving...
The testcase in comment 2 works now (20050730), so marking this fixed per comment 5.
Status: ASSIGNED → RESOLVED
Last Resolved: 14 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.