Open
Bug 501501
Opened 16 years ago
Updated 2 years ago
setInterval/setTimeout aren't working anymore after alert()
Categories
(Core :: DOM: Core & HTML, defect)
Core
DOM: Core & HTML
Tracking
()
NEW
People
(Reporter: christopher.blum, Assigned: smaug)
References
()
Details
(Keywords: testcase)
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 6.0; de; rv:1.9.1) Gecko/20090624 Firefox/3.5
Build Identifier: Mozilla/5.0 (Windows; U; Windows NT 6.0; de; rv:1.9.1) Gecko/20090624 Firefox/3.5
Hi,
I found a bug which occures in Firefox 3 and 3.5 (on Mac Leopard and Windows Vista)
An alert message which is triggered by an ajax callback method causes setTimeout/setInterval to stop working in all following pages in the same tab.
How to reproduce this:
- Start an ajax request within an iframe
- Define a callback method which shows an alert() message if the readyState is "2" (loaded)
- When an user leaves the page before the ajax request has succeeded the readyState is for some reason "2" and therefore the alert message is shown
- On every following page setInterval/setTimeout don't working anymore (silently)
- Only a closing and reopening the tab fixes the problem
I prepared a test page:
First, go to the following page and click the link:
http://sendsome.org/dump/ffbug/setTimeout.php
You'll see that the setTimeout callback is triggered correctly.
Now go to the following page which contains an iframe that sends an ajax request which takes 5 seconds to finish:
http://sendsome.org/dump/ffbug/index.php
Click the link on the page within those 5 seconds. You'll see the mentioned alert() message and you'll be redirected to the setTimeout test-page. Now click the link again. It won't trigger the setTimeout callback even if you refresh the page and try again.
It only happens when the ajax request is started within the iframe.
This bug should not be underrated since a lot of web applications (e.g. OpenSocial Gadgets) run within an iframe and even more web applications are using setTimeout/setInterval (e.g. for doing fancy effects)
Reproducible: Always
Comment 1•16 years ago
|
||
This seems to be a duplicate of Bug 418493 and is caused by Bug 52209.
Assignee: general → nobody
Component: JavaScript Engine → DOM
QA Contact: general → general
Reporter | ||
Comment 2•16 years ago
|
||
I disagree, Ria.
I don't think that this is a duplicate of Bug 418493 since this has nothing to do with a timeout that is blocked by an alert.
The setTimeout in my example is initiated after the alert is closed.
Assignee | ||
Comment 3•16 years ago
|
||
Bent, I think this might have something to do with Sync XHR and timeouts.
(Btw, one can easily lock up the whole Safari with testcases similar to the one in this bug.)
Comment 4•16 years ago
|
||
This is similar to bug 497909 (which itself may be a dupe of bug 418493).
Comment 5•16 years ago
|
||
Regression range is http://bonsai.mozilla.org/cvsquery.cgi?module=PhoenixTinderbox&date=explicit&mindate=2006-10-05+07%3A00&maxdate=2006-10-05+14%3A00 in any case :/
Assignee | ||
Comment 6•16 years ago
|
||
Oh, then it isn't what I was a bit afraid of.
Status: UNCONFIRMED → NEW
Ever confirmed: true
Reporter | ||
Comment 7•16 years ago
|
||
(In reply to comment #3)
> Bent, I think this might have something to do with Sync XHR and timeouts.
>
> (Btw, one can easily lock up the whole Safari with testcases similar to the one
> in this bug.)
I am not using a synchronous xhr in my example.
Assignee | ||
Comment 8•16 years ago
|
||
Indeed, my mistake.
Reporter | ||
Comment 9•16 years ago
|
||
Could at least anyone confirm this bug?
Is there anything I can do to help you guys fixing that?
Thanks.
Assignee | ||
Updated•15 years ago
|
Flags: wanted1.9.2?
Flags: blocking1.9.2?
Assignee | ||
Comment 10•15 years ago
|
||
This is a very old regression, but we should fix this anyway.
Assignee | ||
Updated•15 years ago
|
Assignee: nobody → Olli.Pettay
Assignee | ||
Updated•15 years ago
|
Flags: blocking1.9.2?
Comment 11•14 years ago
|
||
I can reproduce the problem using Christopher's testcase with Firefox 4 beta 7.
Comment 12•14 years ago
|
||
This bug is causing a lot of problems for us as we have a lot of alerts in our application which are essential. Any other workarounds for this one?
Assignee | ||
Comment 13•14 years ago
|
||
Does this still happen on FF4?
Comment 14•14 years ago
|
||
Yep, happening on the latest nightlies as well.
Comment 15•14 years ago
|
||
In Firefox 4 beta 12 I cannot reproduce the problem anymore with the testcase from Christopher. Whether the actual problem has disappeared or just isn't trigger anymore (due to the new modal dialogs within the tabs?) I don't know.
Assignee | ||
Updated•13 years ago
|
Flags: wanted1.9.2?
Updated•6 years ago
|
Component: DOM → DOM: Core & HTML
Updated•2 years ago
|
Severity: normal → S3
You need to log in
before you can comment on or make changes to this bug.
Description
•