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-next>] [day] [month] [year] [list]
Date:	Sat, 23 Jul 2016 16:56:14 +0200 (CEST)
From:	Julia Lawall <julia.lawall@...6.fr>
To:	kernel-janitors@...r.kernel.org
cc:	linux-kernel@...r.kernel.org
Subject: is_err checking

Code like the following looks a bit clunky to me:

if (IS_ERR(data->clk) && PTR_ERR(data->clk) != -EPROBE_DEFER)

Is there any reason not to always use eg

data->clk == ERR_PTR(-EPROBE_DEFER)

Code of the latter form is a bit more popular.  Perhaps one could want
something like:

IS_ERR_VALUE(data->clk, -EPROBE_DEFER)

but IS_ERR_VALUE is laready used for something else.

julia

Powered by blists - more mailing lists