[Click] memory leak on creating a new element

Eddie Kohler kohler at cs.ucla.edu
Sat Oct 29 12:37:24 EDT 2005


Hi Kevin,

Yes, I agree with Bart -- please post both pieces of code.

Eddie


On Oct 28, 2005, at 2:34 PM, Qinghua(Kevin) Ye wrote:

> Hi There,
>
> I encoutered a memory leak problem when I create a new element. The  
> elements
> is simple pull processing mode. It pulls serveral packets from its  
> input
> element, stores it in a packets array, and then allocates a new packet
> according to the total length of the packets, copies the content of  
> these
> packets into the new allocated packet and frees the old packets one  
> by one.
> Tests shows that there is memory leak problem.
>
> However, if I pull one packet, copy the packet content, kill it,  
> then pull
> another packet, iteratively, it works ok. Could anyone give some  
> explanation
> of this scheme? Thanks.
>
> Regards,
> Qinghua
>
>
> _______________________________________________
> click mailing list
> click at amsterdam.lcs.mit.edu
> https://amsterdam.lcs.mit.edu/mailman/listinfo/click
>



More information about the click mailing list