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] [day] [month] [year] [list]
Date:   Tue, 21 Mar 2023 15:08:28 +0100
From:   Jan Kara <jack@...e.cz>
To:     Colin Ian King <colin.i.king@...il.com>
Cc:     Jan Kara <jack@...e.com>, linux-ext4@...r.kernel.org,
        kernel-janitors@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH][next] ext2: remove redundant assignment to pointer end

On Fri 17-03-23 14:34:20, Colin Ian King wrote:
> Pointer is assigned a value that is never read, the assignment is
> redundant and can be removed.
> 
> Cleans up clang-scan warning:
> fs/ext2/xattr.c:555:3: warning: Value stored to 'end' is never read [deadcode.DeadStores]
>                 end = (char *)header + sb->s_blocksize;
> 
> Signed-off-by: Colin Ian King <colin.i.king@...il.com>

Thanks. I've picked the patch to my tree.

								Honza

> ---
>  fs/ext2/xattr.c | 1 -
>  1 file changed, 1 deletion(-)
> 
> diff --git a/fs/ext2/xattr.c b/fs/ext2/xattr.c
> index b126af5f8b15..8906ba479aaf 100644
> --- a/fs/ext2/xattr.c
> +++ b/fs/ext2/xattr.c
> @@ -552,7 +552,6 @@ ext2_xattr_set(struct inode *inode, int name_index, const char *name,
>  		error = -ENOMEM;
>  		if (header == NULL)
>  			goto cleanup;
> -		end = (char *)header + sb->s_blocksize;
>  		header->h_magic = cpu_to_le32(EXT2_XATTR_MAGIC);
>  		header->h_blocks = header->h_refcount = cpu_to_le32(1);
>  		last = here = ENTRY(header+1);
> -- 
> 2.30.2
> 
-- 
Jan Kara <jack@...e.com>
SUSE Labs, CR

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ