lkml.org 
[lkml]   [2013]   [Nov]   [14]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH] ramfs: Fix memory leak on ramfs_fill_super error paths
On Thu, Nov 14, 2013 at 02:59:19PM +0800, Axel Lin wrote:
> The memory leak was introduced by commit 318ceed0884
> "tidy up after d_make_root() conversion".

No memory leaks there. Note that ->kill_sb() is called in *all*
cases, so that kfree() will be done by it just fine.

It's *not* ->put_super() - that would've been called only for superblocks
that had passed mount. ->kill_sb() is called for *all* of them and
that often simplifies cleanup on failure exits quite nicely.


\
 
 \ /
  Last update: 2013-11-14 15:21    [W:0.042 / U:0.212 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site