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: <ZJ3aa4jfxoWBc6Q0@corigine.com>
Date:   Thu, 29 Jun 2023 21:24:27 +0200
From:   Simon Horman <simon.horman@...igine.com>
To:     Andy Shevchenko <andriy.shevchenko@...ux.intel.com>
Cc:     Jakub Kicinski <kuba@...nel.org>, netdev@...r.kernel.org,
        linux-kernel@...r.kernel.org,
        "David S. Miller" <davem@...emloft.net>,
        Eric Dumazet <edumazet@...gle.com>,
        Paolo Abeni <pabeni@...hat.com>
Subject: Re: [PATCH v1 1/1] netlink: Don't use int as bool in
 netlink_update_socket_mc()

On Thu, Jun 29, 2023 at 09:55:50PM +0300, Andy Shevchenko wrote:
> On Thu, Jun 29, 2023 at 05:11:23PM +0200, Simon Horman wrote:
> > On Thu, Jun 29, 2023 at 04:31:31PM +0300, Andy Shevchenko wrote:
> 
> > > -	int old, new = !!is_new, subscriptions;
> > > +	int subscriptions;
> > > +	bool old;
> > >  
> > >  	old = test_bit(group - 1, nlk->groups);
> > >  	subscriptions = nlk->subscriptions - old + new;
> > 
> > Hi Andy,
> > 
> > Doing arithmetic with boolean values doesn't seem right to me.
> 
> In any case it does not change the status quo, the same still applies to
> the existing code (that's implied in the commit message). And obfuscating
> it for the sake of purity seems wrong to me. Hence this patch.

Yes, sure. That is true.

> > In any case, net-next is closed.
> > Please consider reposting once it re-opens, after 10th July.
> 
> Sure.
> 
> Thank you for the review!
> 
> -- 
> With Best Regards,
> Andy Shevchenko
> 
> 
> 

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ