What if I don't free() all my dynamically allocated memory?

Lawrence C Foard lfoard at wpi.wpi.edu
Tue Apr 11 04:08:21 AEST 1989


Does any one know if dos/turbo C is able to put small blocks of memory back together
again? I have a program that allocates memory in 512 bytes chunks which also
has to call other programs. The memory can all be farfreed before a call to
another program, will turbo C and dos make the freed memory available to the
spawned process. The two problems I can see is 
1) Turbo C may not return the freed memory to dos
2) Dos may not put the 512 byte chunks back together to make big (64K) chunks.

Does any one know is either of these problems actually happen and if so can
they be fixed (or otherwise gotten around).
 
-- 
Disclaimer: My school does not share my views about FORTRAN.
            FORTRAN does not share my views about my school.



More information about the Comp.lang.c mailing list