lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <05f5d38b-9569-6ec7-534f-9a3a5ecd5faa@gmx.com>
Date:   Sat, 4 Aug 2018 20:29:49 +0800
From:   Su Yue <Damenly_Su@....com>
To:     zhong jiang <zhongjiang@...wei.com>, clm@...com, jbacik@...com,
        dsterba@...e.com
Cc:     linux-btrfs@...r.kernel.org, linux-kernel@...r.kernel.org,
        Su Yue <suy.fnst@...fujitsu.com>
Subject: Re: [PATCH] btrfs/extent_map: Remove unneeded variable "ret"



On 2018/8/4 7:13 PM, zhong jiang wrote:
> The ret is not used after initalization, So just remove it.
> 
> Signed-off-by: zhong jiang <zhongjiang@...wei.com>

Reviewed-by: Su Yue <suy.fnst@...fujitsu.com>
> ---
>   fs/btrfs/extent_map.c | 8 +++-----
>   1 file changed, 3 insertions(+), 5 deletions(-)
> 
> diff --git a/fs/btrfs/extent_map.c b/fs/btrfs/extent_map.c
> index 6648d55..b48ab41 100644
> --- a/fs/btrfs/extent_map.c
> +++ b/fs/btrfs/extent_map.c
> @@ -276,7 +276,6 @@ static void try_merge_map(struct extent_map_tree *tree, struct extent_map *em)
>   int unpin_extent_cache(struct extent_map_tree *tree, u64 start, u64 len,
>   		       u64 gen)
>   {
> -	int ret = 0;
>   	struct extent_map *em;
>   	bool prealloc = false;
>   
> @@ -308,7 +307,7 @@ int unpin_extent_cache(struct extent_map_tree *tree, u64 start, u64 len,
>   	free_extent_map(em);
>   out:
>   	write_unlock(&tree->lock);
> -	return ret;
> +	return 0;
>   
>   }
>   
> @@ -430,14 +429,13 @@ struct extent_map *search_extent_mapping(struct extent_map_tree *tree,
>    */
>   int remove_extent_mapping(struct extent_map_tree *tree, struct extent_map *em)
>   {
> -	int ret = 0;
> -
>   	WARN_ON(test_bit(EXTENT_FLAG_PINNED, &em->flags));
>   	rb_erase(&em->rb_node, &tree->map);
>   	if (!test_bit(EXTENT_FLAG_LOGGING, &em->flags))
>   		list_del_init(&em->list);
>   	RB_CLEAR_NODE(&em->rb_node);
> -	return ret;
> +
> +	return 0;
>   }
>   
>   void replace_extent_mapping(struct extent_map_tree *tree,
> 

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ