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]
Message-ID: <20180915051032.GA23900@flashbox>
Date:   Fri, 14 Sep 2018 22:10:32 -0700
From:   Nathan Chancellor <natechancellor@...il.com>
To:     Sudeep Holla <sudeep.holla@....com>
Cc:     Jean Delvare <jdelvare@...e.com>,
        Guenter Roeck <linux@...ck-us.net>,
        linux-hwmon@...r.kernel.org, linux-kernel@...r.kernel.org,
        Nick Desaulniers <ndesaulniers@...gle.com>
Subject: Clang warning in drivers/hwmon/scmi-hwmon.c

Hi Sundeep and others,

A group of us are trying to clean up all the warnings we see with an
'allyesconfig' arm64 build done with Clang and this one came up:

drivers/hwmon/scmi-hwmon.c:59:24: warning: address of array 'sensor->name' will always evaluate to 'true' [-Wpointer-bool-conversion]
        if (sensor && sensor->name)
                   ~~ ~~~~~~~~^~~~
1 warning generated.

Would it be appropriate to just delete that check or does the check
need to be adjusted in some way (such as checking for the first value
'sensor->name[0]')? Either option technically solves the warning but I
don't have the hardware to check if this breaks the driver.

Thanks,
Nathan

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ