[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <7da316f4-aa65-896e-9020-2dfff2bbfc09@gmail.com>
Date: Sat, 12 Mar 2022 18:16:09 +0300
From: Pavel Skripkin <paskripkin@...il.com>
To: Ryusuke Konishi <konishi.ryusuke@...il.com>,
Dongliang Mu <mudongliangabcd@...il.com>
Cc: Andrew Morton <akpm@...ux-foundation.org>,
linux-nilfs <linux-nilfs@...r.kernel.org>,
LKML <linux-kernel@...r.kernel.org>,
Nanyong Sun <sunnanyong@...wei.com>,
慕冬亮 <dzm91@...t.edu.cn>
Subject: Re: Fw:Re: [PATCH] fs: nilfs2: fix memory leak in nilfs sysfs create
device group
Hi Ryusuke,
On 3/12/22 18:11, Ryusuke Konishi wrote:
>> In case of nilfs_attach_log_writer() error code jumps to
>> failed_checkpoint label and calls destroy_nilfs() which should call
>> nilfs_sysfs_delete_device_group().
>
> nilfs_sysfs_delete_device_group() is called in destroy_nilfs()
> if nilfs->ns_flags has THE_NILFS_INIT flag -- nilfs_init() inline
> function tests this flag.
>
> The flag is set after init_nilfs() succeeded at the beginning of
> nilfs_fill_super() because the set_nilfs_init() inline in init_nilfs() sets it.
>
> So, nilfs_sysfs_delete_group() seems to be called in case of
> the above failure. Am I missing something?
>
Yeah, that's what I mean :) I can't see how reported issue is possible
with current code.
Sorry for not being clear
With regards,
Pavel Skripkin
Powered by blists - more mailing lists