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]
Message-ID: <CAK7LNAS0vPy0nY8YqzsWWoSB5rgxqSe9_KLCsJoUAu_F5=57iQ@mail.gmail.com>
Date:   Sun, 26 Apr 2020 01:59:14 +0900
From:   Masahiro Yamada <masahiroy@...nel.org>
To:     Linux Kbuild mailing list <linux-kbuild@...r.kernel.org>
Cc:     Linux Kernel Mailing List <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH] kconfig: do not use OR-assignment for zero-cleared structure

On Tue, Apr 14, 2020 at 12:33 AM Masahiro Yamada <masahiroy@...nel.org> wrote:
>
> The simple assignment is enough because memset() three lines above
> has zero-cleared the structure.
>
> Signed-off-by: Masahiro Yamada <masahiroy@...nel.org>
> ---
>
>  scripts/kconfig/symbol.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/scripts/kconfig/symbol.c b/scripts/kconfig/symbol.c
> index 3dc81397d003..9363e37b8870 100644
> --- a/scripts/kconfig/symbol.c
> +++ b/scripts/kconfig/symbol.c
> @@ -831,7 +831,7 @@ struct symbol *sym_lookup(const char *name, int flags)
>         memset(symbol, 0, sizeof(*symbol));
>         symbol->name = new_name;
>         symbol->type = S_UNKNOWN;
> -       symbol->flags |= flags;
> +       symbol->flags = flags;
>
>         symbol->next = symbol_hash[hash];
>         symbol_hash[hash] = symbol;
> --
> 2.25.1
>

Applied to linux-kbuild.


-- 
Best Regards
Masahiro Yamada

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ