Changes between Version 2 and Version 3 of Ticket #6242, comment 24
- Timestamp:
- Dec 6, 2010, 8:28:21 PM (12 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
Ticket #6242, comment 24
v2 v3 1 The leak happened because the attached function references the original object via a closure. This causes a circular reference that IE’s garbage collector does not know how to handle. `jQuery.noop` does not go outside its own private scope and thus is not susceptible to this issue.1 The leak happened because the attached function references the original object via a closure. This causes a circular reference that IE’s garbage collector does not know how to handle. Dereferencing the function that generated the closure resolves the circular reference and allows GC to occur. 2 2 3 3 In my testing, after several tens of thousands of XHR calls, memory usage remained flat in IE6-8 with this fix, whereas it increased by several MB/s when the leak was occurring.