Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Posting-Version: version B 2.10.2 9/5/84; site oliveb.UUCP Path: utzoo!watmath!clyde!burl!ulysses!allegra!oliveb!bb From: bb@oliveb.UUCP (Bart Berger) Newsgroups: net.micro.pc Subject: Re: Removing a memory-resident program -- Help Message-ID: <638@oliveb.UUCP> Date: Wed, 20-Nov-85 20:20:09 EST Article-I.D.: oliveb.638 Posted: Wed Nov 20 20:20:09 1985 Date-Received: Sat, 23-Nov-85 00:30:45 EST References: <280@well.UUCP> Organization: Olivetti ATC; Cupertino, Ca Lines: 17 > When removing a previously loaded memory-resident program we cannot > recover all of the memory. It appears that DOS keeps 64 bytes each > time. What's the trick to getting back ALL of your memory when > removing a resident program?? > Doug Kaye > Rational Data Systems > ihnp4!hplabs!well!drk I believe that 64 bytes is the copy of the environment table that MS-DOS makes for each program. The trick is: before releasing the program's memory, release the environment table's memory. The segment address of the environment table is at offset 2C in the Program Segment Prefix; pass that segment address to MS-DOS function 49h to release the environment table space. (Caveat: I haven't tried this yet.) Bart Berger ...!oliveb!bb