Path: utzoo!utgpu!water!watmath!clyde!att!osu-cis!tut.cis.ohio-state.edu!mailrus!ames!pasteur!ucbvax!decwrl!univse.dec.com!shatara From: shatara@univse.dec.com (Chris Shatara, Chelmsford, Ma.) Newsgroups: comp.sys.apple Subject: Help with //gs Memory Manager commands Message-ID: <8810311658.AA01121@decwrl.dec.com> Date: 31 Oct 88 16:58:35 GMT Organization: Digital Equipment Corporation Lines: 35 I am having a problem with my understanding of the UnlockAll and DisposeAll commands of the Memory manager. I have a TML Pascal program where I form a binary tree of Handles (Actualy pointers made from LOCKED handles). This is in the body of a program I created for generating CrossReference listings of my programs. Memory for each identifier is allocated using the NewHandle command with the Aux field of the Memory ID set to $1. This is accomplished via XrefMemId := BitOr(MyMemoryId,$0100); ( MyMemoryId is the master ID returned from the memory mgr) Now my question...... When I'm through printing out the cross reference listing, I want to deallocate and free up the space which was locked for each of the identifiers in my binary tree. I did the following: UnLockAll(XrefMemID) {unlock all pointer with this ID} DisposeAll(XrefMemID) {free up the memory space..I think} Invoking FreeMem before and after the above commands shows that I am not gaining back memory that was allocated and in fact I'm losing more. Am I interpreting these command wrongly? I tried PurgeAll(XrefMemID) in place of DisposeAll and had the same results? Regards, Chris Shatara