Subject: | Memory leaks |
Date: | Wed, 10 Feb 2010 10:40:31 +1100 |
To: | <bug-SVG [...] rt.cpan.org> |
From: | "Tulloh, David" <david.tulloh [...] AirservicesAustralia.com> |
The SVG object doesn't clean up after itself resulting in memory leaks
as the program runs.
Due to all the self references scattered through the tree the SVG object
can't fall out of scope or be destroyed by being set to undef. (It is
cleaned up when the script completes.)
A destructor should be defined in the SVG class to allow Perl to destroy
the object cleanly.
I have attached a script that demonstrates the problem. It also
includes workaround code that I have created, this code may not catch
all references but seems to work for the SVG objects I am generating.
Using:
Perl v5.10.1
SVG 2.49
Debian Linux, kernel 2.6.32, running in a VM
Message body is not shown because sender requested not to inline it.