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: <20220801091735.GB3460@kadam>
Date:   Mon, 1 Aug 2022 12:17:36 +0300
From:   Dan Carpenter <dan.carpenter@...cle.com>
To:     Joe Perches <joe@...ches.com>
Cc:     Phillip Potter <phil@...lpotter.co.uk>, gregkh@...uxfoundation.org,
        Larry.Finger@...inger.net, paskripkin@...il.com, martin@...ser.cx,
        straube.linux@...il.com, fmdefrancesco@...il.com,
        abdun.nihaal@...il.com, linux-staging@...ts.linux.dev,
        linux-kernel@...r.kernel.org
Subject: Re: [PATCH 2/2] staging: r8188eu: convert rtw_set_802_11_add_wep
 error code semantics

On Sun, Jul 31, 2022 at 10:12:56AM -0700, Joe Perches wrote:
> > I'm happy of course to rewrite this to address any concerns, but
> > I was hoping I could clarify what you've said though? Apologies if I've
> > missed it, but how is this function now returning 1 on success? It sets
> > ret to 0 (success) at the start and then sets it to one of two negative
> > error codes depending on what happens. Am I missing something here?
> > (Perfectly possible that I am).
> > 
> > In terms of do nothing gotos, do you mean gotos that just set an error
> > code then jump to the end? If you'd prefer, as the function just returns
> > right after the exit label, I can just return the codes directly and have
> > a 'return 0;' like you say above?
> > 
> > Thanks as always for your insight.
> 
> Yes, you've got it right.
> 
> I think Dan is suggesting something like the below, but
> not necessarily in a single patch:

I always like your style, Joe.

regards,
dan carpenter

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ