memory - why isn't it getting freed

J. Landman Gay jacque at hyperactivesw.com
Mon Aug 9 18:08:51 EDT 2004


On 8/9/04 9:00 AM, Chris Sheffield wrote:

> Can anyone tell me the reasons for memory not getting freed up like it
> should?
> 
> I have an application that consists of a login stack, another main stack
> where most of the program functionality occurs, and then several other
> external stacks (stored as compressed data in a Valentina database) that
> contain multimedia content such as graphics, audio files, text, etc.  These
> stacks get extracted from the database, decompressed, and then accessed to
> retrieve that content.  The problem is, when I’m done with these external
> stacks, I use the delete stack command, which should remove them from
> memory, but it doesn’t.  I have checked every function I can think of
> (revLoadedStacks, openStacks, stacksInUse, etc.) to see if Rev thinks these
> stacks are still open in some way, but that is not the case.  The memory
> just doesn’t get freed.  It doesn’t return to normal until I completely exit
> my application.  This is not a good thing because used memory keeps building
> up and up, until eventually the application crashes because the system has
> run out of memory.
> 
> This is a serious problem, and I’m not sure if it’s something I’m doing
> wrong, or if I’ve discovered some bug in Rev.  So what I’m wondering is,
> what would cause memory to not get freed the way it should?  Files that the
> stacks might have open perhaps?  But if that were the case, why would the
> stack not appear when using one of the above functions?  Anything else?

Does this happen only in the IDE, or in the standalone as well? If it is 
only in the IDE, then it may be that Rev's preferences are set to keep 
the stack open regardless of what command is used to close it. Rev will 
override the close command and the destroystack property when this 
preference is set.

If it is happening in a standalone, then I'm afraid I don't know why. I 
haven't seen that behavior, but then, I haven't specifically checked for 
it either.

-- 
Jacqueline Landman Gay         |     jacque at hyperactivesw.com
HyperActive Software           |     http://www.hyperactivesw.com


More information about the use-livecode mailing list