[Ocfs2-tools-devel] [PATCH 2/2] libocfs2: avoid dead code

Sunil Mushran sunil.mushran at oracle.com
Mon Sep 19 09:02:54 PDT 2011


NAK

I would rather not make a patch out of this change. We have maybe
a thousand places where we do this. The idea is to fix it when we make
another change in the same place.

On 09/19/2011 08:27 AM, chuanchang.jia at gmail.com wrote:
> libocfs2/dir_indexed.c: avoid dead code.
>
> Signed-off-by: Alex Jia<chuanchang.jia at gmail.com>
> ---
>   libocfs2/dir_indexed.c |    3 +--
>   1 files changed, 1 insertions(+), 2 deletions(-)
>
> diff --git a/libocfs2/dir_indexed.c b/libocfs2/dir_indexed.c
> index a195ea5..aea04aa 100644
> --- a/libocfs2/dir_indexed.c
> +++ b/libocfs2/dir_indexed.c
> @@ -1481,8 +1481,7 @@ errcode_t ocfs2_dx_dir_search(ocfs2_filesys *fs,
>   	}
>   	ret = 0;
>   out:
> -	if (di_buf)
> -		ocfs2_free(&di_buf);
> +	ocfs2_free(&di_buf);
>   	if (ret) {
>   		if (dir_buf)
>   			ocfs2_free(&dir_buf);




More information about the Ocfs2-tools-devel mailing list