[Ocfs2-tools-devel] [PATCH] tunefs.ocfs2: fix double free bug

piaojun piaojun at huawei.com
Fri Oct 28 02:19:39 PDT 2016


Thanks for fixing the mistake I made before, this patch looks good to me.

thanks,
Jun Piao

On 2016-10-28 15:59, Junxiao Bi wrote:
> Fixes: 79ec217ccd03("tunefs.ocfs2: fix memory leak problems in tunefs_journal_check() and parse_options()")
> Signed-off-by: Junxiao Bi <junxiao.bi at oracle.com>
> ---
>  tunefs.ocfs2/libocfs2ne.c |    1 +
>  1 file changed, 1 insertion(+)
> 
> diff --git a/tunefs.ocfs2/libocfs2ne.c b/tunefs.ocfs2/libocfs2ne.c
> index 20bee9f4106b..240c1d94fef8 100644
> --- a/tunefs.ocfs2/libocfs2ne.c
> +++ b/tunefs.ocfs2/libocfs2ne.c
> @@ -1795,6 +1795,7 @@ static errcode_t tunefs_journal_check(ocfs2_filesys *fs)
>  		state->ts_journal_features.opt_incompat |=
>  			jsb->s_feature_incompat;
>  		ocfs2_free_cached_inode(fs, ci);
> +		ci = NULL;
>  	}
>  
>  	/*
> 




More information about the Ocfs2-tools-devel mailing list