#466 enhancement
christophe CAMENSULI

Suppress memory leaks from Element.remove and Elemen.update

Reported by christophe CAMENSULI | November 26th, 2008 @ 04:42 PM | in 2.0

The attached patch fixes memory leaks which occur with all browsers on Element.remove and Element.update.

Since it is not always possible to stop all the events during the life cycle of our application, we use the garbage event (Event.cache) of prototype to stop all events with the function Element.remove and Element.update. Deleting all DOM child nodes improves memory footprint benchmarks too.

We benchmarked the memory footprint of various browsers with and without this patch by running a create-remove-update cycle 10000 times.

This patch works with Safari Firefox Opera IE8, but could not be tested with IE7.

Comments and changes to this ticket

Please Sign in or create a free account to add a new ticket.

With your very own profile, you can contribute to projects, track your activity, watch tickets, receive and update tickets through your email and much more.

New-ticket Create new ticket

Create your profile

Help contribute to this project by taking a few moments to create your personal profile. Create your profile ยป

The Prototype JavaScript library.

Shared Ticket Bins

Referenced by