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: <19abedb11fae1b96aa052090e7a0d5bbea416824.camel@perches.com>
Date:   Mon, 09 Mar 2020 12:30:07 -0700
From:   Joe Perches <joe@...ches.com>
To:     Daniel Xu <dxu@...uu.xyz>, viro@...iv.linux.org.uk,
        linux-fsdevel@...r.kernel.org, linux-kernel@...r.kernel.org
Cc:     kernel-team@...com
Subject: Re: [PATCH] xattr: NULL initialize name in simple_xattr_alloc

On Mon, 2020-03-09 at 11:37 -0700, Daniel Xu wrote:
> It's preferable to initialize structs to a deterministic state.

Thanks Daniel.

> Signed-off-by: Daniel Xu <dxu@...uu.xyz>
> ---
>  fs/xattr.c | 1 +
>  1 file changed, 1 insertion(+)
> 
> diff --git a/fs/xattr.c b/fs/xattr.c
> index 90dd78f0eb27..92b324c265d2 100644
> --- a/fs/xattr.c
> +++ b/fs/xattr.c
> @@ -821,6 +821,7 @@ struct simple_xattr *simple_xattr_alloc(const void *value, size_t size)
>  	if (!new_xattr)
>  		return NULL;
>  
> +	new_xattr->name = NULL;
>  	new_xattr->size = size;
>  	memcpy(new_xattr->value, value, size);
>  	return new_xattr;

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ