Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl Monk, Perl Meditation
 
PerlMonks  

Re: Do I need to free allocated space in an END sub?

by gmpassos (Priest)
on Dec 11, 2004 at 00:46 UTC ( #414027=note: print w/ replies, xml ) Need Help??


in reply to Do I need to free allocated space in an END sub?

If you are using END just to free the memory you don't need because after call END (in a normal Perl process) we have the global destruction, where everything will be destroied and cleaned.

The usage of end is only needed if you need to make some operations like save things to a file, unlock DB tables, etc... So, is only needed for things that will still exists after the process be dead, in other words, only metters for things outside of your process.

Graciliano M. P.
"Creativity is the expression of liberty".


Comment on Re: Do I need to free allocated space in an END sub?

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://414027]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others contemplating the Monastery: (7)
As of 2015-08-01 00:41 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    The top three priorities of my open tasks are (in descending order of likelihood to be worked on) ...









    Results (285 votes), past polls