Re: Question re: freeing structs [NEWBIE]

From: Daniel A. Koepke (
Date: 10/14/02

On Mon, 14 Oct 2002, Mathew Earle Reuther wrote:

> If I remove those, it no longer complains.  It is my understandng from
> this that simply by freeing the structure itself, the integers are
> freed?

You need only free what you allocate.  Another way of looking at this is
that one doesn't free pointers, but the memory that they point to.
(Consequently, you never call free() on something that's not a pointer,
and you only call free() on some pointers.)


   | FAQ: |
   | Archives: |
   | Newbie List:   |

This archive was generated by hypermail 2b30 : 06/25/03 PDT