setInterval memory leak
Reported by
vidar.e....@gmail.com,
Nov 6 2017
|
||||
Issue descriptionUserAgent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/63.0.3239.30 Safari/537.36 Steps to reproduce the problem: 1. Use setInterval to change the content of an HTML element every second. 2. 3. What is the expected behavior? Regular garbage collection. What went wrong? No garbage collection occurs, at all. Both heap size and node count increases incessantly. https://stackoverflow.com/questions/47077887/setinterval-memory-leak Did this work before? No Chrome version: 63.0.3239.30 Channel: beta OS Version: 10.0 Flash Version: I'm trying to create a simple javascript clock. Our clients use our single page app for several days without refreshing the page, so this is a real resource hog for us that eventually crashes the tab.
,
Nov 7 2017
I am not sure how? Do I just post the code in this comment? The link contains the testcase.
JavaScript:
updateClock = function() {
document.getElementById('myDateTime').textContent = new Date();
}
setInterval(updateClock, 1000);
HTML:
<div id="myDateTime"></div>
,
Nov 7 2017
,
Nov 12 2017
I have an demo page (meant to show the catch-up effect of setInterval()) which probably can be used to demonstrate this issue: https://bl.ocks.org/Herst/f40207373c9f983cfba2e79442b51129 Select "setInterval" in the select box for the counter to start.
,
Nov 13 2017
Unable to triage this issue from TE-End, hence adding TE-NeedsTriageHelp label for further triage from dev team
,
Nov 13
Issue has not been modified or commented on in the last 365 days, please re-open or file a new bug if this is still an issue. For more details visit https://www.chromium.org/issue-tracking/autotriage - Your friendly Sheriffbot |
||||
►
Sign in to add a comment |
||||
Comment 1 by ligim...@chromium.org
, Nov 6 2017