The MASM Forum Archive 2004 to 2012

General Forums => The Campus => Topic started by: Maeser on February 27, 2006, 05:49:21 AM

Title: Expansion on previous "Memory Loss" question
Post by: Maeser on February 27, 2006, 05:49:21 AM
I have a buffer thats allocated as Local in a procedure...now will I have to free that buffer every time or will it be smart enough for me? Not so much exiting the program as finishing the procedure.


Thanks

(Again, apologies for my other thread. I was still stuck in java mode)
Title: Re: Expansion on previous "Memory Loss" question
Post by: Mark Jones on February 27, 2006, 05:53:18 AM
Hi Maeser, "local" vars are created on the stack, so after that procedure exits, further stack operations just overwrite that data as needed. It truly is treated as local data. :)
Title: Re: Expansion on previous "Memory Loss" question
Post by: Maeser on February 27, 2006, 08:16:16 AM
Sweet. :D Thanks a lot