[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Does dropping objects really free memory?
From: |
Fabio Mascelloni |
Subject: |
Re: Does dropping objects really free memory? |
Date: |
Thu, 21 Oct 1999 11:25:08 +0200 |
----- Original Message -----
From: Marcus G. Daniels <address@hidden>
To: <address@hidden>
Sent: Wednesday, October 20, 1999 10:19 PM
Subject: Re: Does dropping objects really free memory?
> >>>>> "MD" == Marcus G Daniels <address@hidden> writes:
>
> MD> You'll want to drop the selfConfig block...
>
> Btw, in setLength: you use calloc to get memory for selfConfig. Then
> in copy: you use alloc: for selfConfig. Since alloc: encodes some
> information in start of the block it gets from malloc, you can't just
> use "free (pointerFromAlloc)". Likewise, you can't use `free:' on the
> result of a calloc.
>
That's was the problem; I got an A.S.V when I tried to drop an object
created through the 'copy' method that uses
Zone's alloc, while in the definition of Coalition's 'drop' method I only
used 'free (selfConfig)'.Now I've made the necessary changes and all goes
perfectly; the memory leaks have been defeated,too (and this makes me
particulary happy because I was struggling with them since I begun my
project).
However , I'd have not gone so far without your precious help (and that of
Paul).
Thank you,
Fabio.
==================================
Swarm-Support is for discussion of the technical details of the day
to day usage of Swarm. For list administration needs (esp.
[un]subscribing), please send a message to <address@hidden>
with "help" in the body of the message.
- Re: Does dropping objects really free memory?, (continued)
Re: Does dropping objects really free memory?, Marcus G. Daniels, 1999/10/19
Re: Does dropping objects really free memory?, famasce, 1999/10/20