Re: [e2fsprogs PATCH] libext2fs: remove unused variable in ext2fs_xattrs_read_inode()

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Wed, Jan 04, 2023 at 01:03:14AM -0800, Eric Biggers wrote:
> From: Eric Biggers <ebiggers@xxxxxxxxxx>
> 
> Address the following compiler warning with gcc -Wall:
> 
> ext_attr.c: In function ‘ext2fs_xattrs_read_inode’:
> ext_attr.c:1000:16: warning: unused variable ‘i’ [-Wunused-variable]
>  1000 |         size_t i;
>       |                ^

You might as well remove the unnecessary newline at the top of the
function.

But regardless, you can add.

Reviewed-by: Lukas Czerner <lczerner@xxxxxxxxxx>

Thanks!
-Lukas

> 
> Cc: Andreas Dilger <adilger@xxxxxxxxx>
> Signed-off-by: Eric Biggers <ebiggers@xxxxxxxxxx>
> ---
>  lib/ext2fs/ext_attr.c | 1 -
>  1 file changed, 1 deletion(-)
> 
> diff --git a/lib/ext2fs/ext_attr.c b/lib/ext2fs/ext_attr.c
> index d36fe68d..6fc4214c 100644
> --- a/lib/ext2fs/ext_attr.c
> +++ b/lib/ext2fs/ext_attr.c
> @@ -997,7 +997,6 @@ errcode_t ext2fs_xattrs_read_inode(struct ext2_xattr_handle *handle,
>  	unsigned int storage_size;
>  	char *start, *block_buf = NULL;
>  	blk64_t blk;
> -	size_t i;
>  	errcode_t err = 0;
>  
>  	EXT2_CHECK_MAGIC(handle, EXT2_ET_MAGIC_EA_HANDLE);
> -- 
> 2.39.0
> 




[Index of Archives]     [Reiser Filesystem Development]     [Ceph FS]     [Kernel Newbies]     [Security]     [Netfilter]     [Bugtraq]     [Linux FS]     [Yosemite National Park]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Samba]     [Device Mapper]     [Linux Media]

  Powered by Linux