HackTimer icon indicating copy to clipboard operation
HackTimer copied to clipboard

excessive memory leaking

Open seiyria opened this issue 9 years ago • 5 comments

over time, if used for a really long time (8-36 hours) this causes a webpage to become incredibly slow. tested with and without on a project and the speed does not drop if hacktimer is not included.

seiyria avatar Nov 20 '15 14:11 seiyria

thank you for reporting. i will try to find out and fix it.

turuslan avatar Nov 21 '15 20:11 turuslan

FYI: I reckon it's because the callback map is not cleared on successful setTimeout callback. For setTimeouts, the callback map should be cleared even if clearTimeout is not called explicitly.

timotheeg avatar Nov 26 '15 00:11 timotheeg

Thanks to @timotheeg, there was such a mistake of not deleting unused timeout entries. Commit e11f3ed2292062ee1e1aafe3510802a889ea6f96 must fix it.

turuslan avatar Dec 03 '15 19:12 turuslan

I'll give this a try sometime later and see if it's still causing problems. If so, I'll let you know. Thanks!

seiyria avatar Dec 03 '15 19:12 seiyria

In commit e11f3ed2292062ee1e1aafe3510802a889ea6f96 I forgot to update silent version (HackTimer.silent.min.js) (issue 13) that you used (package.json). So it was not fixed that time. Now it is updated (8e2fef9429ec427a54d8b407a2f1130b5a811098, c06bbc674e3c49d9c250e5890724cbf007c53388).

turuslan avatar Jan 18 '16 07:01 turuslan