Messages in this thread | | | Date | Tue, 25 Sep 2012 12:14:29 +0200 | From | David Sterba <> | Subject | Re: [PATCH v2 2/2] btrfs-progs: Fix up memory leakage |
| |
On Tue, Sep 25, 2012 at 10:02:16AM +0800, zwu.kernel@gmail.com wrote: > From: Zhi Yong Wu <wuzhy@linux.vnet.ibm.com> > > Some code pathes forget to free memory on exit.
Same as with the fd's, kernel will free all memory for us at exit().
If there's lots of memory allocated, it may be even faster to leave the unallocation process to kernel as it will do it in one go, while the application would unnecessarily free it chunk by chunk.
david
| |