linux-f2fs-devel.lists.sourceforge.net archive mirror
 help / color / mirror / Atom feed
From: hyeongseok <hyeongseok@gmail.com>
To: Eric Biggers <ebiggers@kernel.org>
Cc: Daniel Rosenberg <drosen@google.com>,
	hyeongseok.kim@lge.com, linux-f2fs-devel@lists.sourceforge.net,
	linux-fsdevel@vger.kernel.org, jaegeuk@kernel.org
Subject: Re: [f2fs-dev] [PATCH] f2fs: fix double free of unicode map
Date: Thu, 12 Nov 2020 17:30:31 +0900	[thread overview]
Message-ID: <41c4c6ac-ccde-1fb9-28bb-b22f8e1c34cb@gmail.com> (raw)
In-Reply-To: <X6zvndTKKQfISlcj@sol.localdomain>

On 11/12/20 5:17 PM, Eric Biggers wrote:
> On Thu, Nov 12, 2020 at 05:02:01PM +0900, Hyeongseok Kim wrote:
>> In case of retrying fill_super with skip_recovery,
>> s_encoding for casefold would not be loaded again even though it's
>> already been freed because it's not NULL.
>> Set NULL after free to prevent double freeing when unmount.
>>
>> Signed-off-by: Hyeongseok Kim <hyeongseok@gmail.com>
>> ---
>>   fs/f2fs/super.c | 1 +
>>   1 file changed, 1 insertion(+)
>>
>> diff --git a/fs/f2fs/super.c b/fs/f2fs/super.c
>> index 00eff2f51807..fef22e476c52 100644
>> --- a/fs/f2fs/super.c
>> +++ b/fs/f2fs/super.c
>> @@ -3918,6 +3918,7 @@ static int f2fs_fill_super(struct super_block *sb, void *data, int silent)
>>   
>>   #ifdef CONFIG_UNICODE
>>   	utf8_unload(sb->s_encoding);
>> +	sb->s_encoding = NULL;
>>   #endif
>>   free_options:
>>   #ifdef CONFIG_QUOTA
>> -- 
> This is:
>
> Fixes: eca4873ee1b6 ("f2fs: Use generic casefolding support")
>
> Right?
>
> - Eric
>
Right. Should I add "Fixes" tag and send v2?



_______________________________________________
Linux-f2fs-devel mailing list
Linux-f2fs-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/linux-f2fs-devel

      reply	other threads:[~2020-11-12  8:30 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-11-12  8:02 [f2fs-dev] [PATCH] f2fs: fix double free of unicode map Hyeongseok Kim
2020-11-12  8:17 ` Eric Biggers
2020-11-12  8:30   ` hyeongseok [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=41c4c6ac-ccde-1fb9-28bb-b22f8e1c34cb@gmail.com \
    --to=hyeongseok@gmail.com \
    --cc=drosen@google.com \
    --cc=ebiggers@kernel.org \
    --cc=hyeongseok.kim@lge.com \
    --cc=jaegeuk@kernel.org \
    --cc=linux-f2fs-devel@lists.sourceforge.net \
    --cc=linux-fsdevel@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).