Mail Archives: djgpp/1997/01/07/02:19:48
Benjamin D Chambers wrote:
>
> When my program exits, is all the allocated memory on freed
> automatically, or is the system retained unless I cal 'free' on all my
> memory blocks (that I allocated with malloc & calloc)?
All memory that is allocated using sbrk(), malloc(), and its family, is
automatically freed by the DJGPP exit code. It is, however, generally
good programming to clean things up yourself (although very few
programmers actually bother to do it).
--
John M. Aldrich, aka Fighteer I <fighteer AT cs DOT com>
-----BEGIN GEEK CODE BLOCK-----
Version: 3.1
GCS d- s+:- a-->? c++>$ U@>++$ p>+ L>++ E>++ W++ N++ o+>++ K? w(---)
O- M-- V? PS+ PE Y+ PGP- t+(-) 5- X- R+(++) tv+() b+++ DI++ D++ G>++
e(*)>++++ h!() !r !y+()
------END GEEK CODE BLOCK------
- Raw text -