Skip to content

Commit f3474c0

Browse files
committed
fix for #5198, event memory leak limited to IE only via conditional compilation
1 parent 4a3c4c8 commit f3474c0

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/event.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -776,11 +776,10 @@ jQuery.each( ("blur,focus,load,resize,scroll,unload,click,dblclick," +
776776
});
777777

778778
// Prevent memory leaks in IE
779-
// And prevent errors on refresh with events like mouseover in other browsers
780779
// Window isn't included so as not to unbind existing unload events
781780
// More info:
782781
// - http://isaacschlueter.com/2006/10/msie-memory-leaks/
783-
// - https://bugzilla.mozilla.org/show_bug.cgi?id=252542
782+
/*@cc_on
784783
jQuery( window ).bind( 'unload', function() {
785784
for ( var id in jQuery.cache ) {
786785
// Skip the window
@@ -789,3 +788,4 @@ jQuery( window ).bind( 'unload', function() {
789788
}
790789
}
791790
});
791+
@*/

0 commit comments

Comments
 (0)