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]
Date:   Sat, 16 Mar 2019 09:31:35 +0100
From:   Michal Hocko <mhocko@...nel.org>
To:     Alexey Dobriyan <adobriyan@...il.com>
Cc:     Tetsuo Handa <penguin-kernel@...ove.sakura.ne.jp>,
        akpm@...ux-foundation.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH 1/2] elf: simpler check for -EEXIST

On Fri 15-03-19 19:05:17, Alexey Dobriyan wrote:
> On Fri, Mar 15, 2019 at 07:02:23AM +0900, Tetsuo Handa wrote:
> > On 2019/03/15 5:42, Alexey Dobriyan wrote:
> > > 	PTR_ERR((void *)map_addr) == -EEXIST
> > > 
> > > is a very complicated way of doing the obvious.
> > 
> > Michal suggested me to explicitly use PTR_ERR()
> 
> without any explanation why...

The return value is ERR_PTR. This code uses unsigned long which is OK
but I thought it is better to call out the return value convention
explicitly. It is not like I would argue about that though.
-- 
Michal Hocko
SUSE Labs

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ