On 07/25/2014 12:55 PM, Chao Yu wrote:
> We should put root inode correctly in error path of fill_super, otherwise we
> may encounter a leak case of inode resource.
Good catch, and it also fixed the incorrect 'goto'.
>
> Signed-off-by: Chao Yu
Reviewed-by: Gu Zheng
> ---
> fs/f2fs/super.c
On 07/25/2014 11:22 AM, Chao Yu wrote:
> Hi,
>
> To Andrey:
> Thanks for your test on this patch!
>
> To Gu:
> If you do not object, let me make and resend a patch base on the one which
> skip invalidating pages.
Please go ahead.:)
Thanks,
Gu
>
> Regards,
> Yu
>
>> -Original Message
We should put root inode correctly in error path of fill_super, otherwise we
may encounter a leak case of inode resource.
Signed-off-by: Chao Yu
---
fs/f2fs/super.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/fs/f2fs/super.c b/fs/f2fs/super.c
index 870fe19..34649aa 1006
Andrey Tsyvarev reported:
"Using memory error detector reveals the following use-after-free error
in 3.15.0:
AddressSanitizer: heap-use-after-free in f2fs_evict_inode
Read of size 8 by thread T22279:
[] f2fs_evict_inode+0x102/0x2e0 [f2fs]
[] evict+0x15f/0x290
[< inlined>] iput+0x1
Hi,
To Andrey:
Thanks for your test on this patch!
To Gu:
If you do not object, let me make and resend a patch base on the one which
skip invalidating pages.
Regards,
Yu
> -Original Message-
> From: Andrey Tsyvarev [mailto:tsyva...@ispras.ru]
> Sent: Thursday, July 24, 2014 6:15 PM
> To
Hi,
With patch skipping invalidating pages for node_inode and meta_inode
use-after-free error disappears too.
23.07.2014 7:39, Gu Zheng пишет:
> Hi,
> On 07/23/2014 10:12 AM, Chao Yu wrote:
>
>> Hi Andrey Gu,
>>
>>> -Original Message-
>>> From: Andrey Tsyvarev [mailto:tsyva...@ispras.ru]