[dm-devel] multipath-tools: new clang warning

Xose Vazquez Perez xose.vazquez at gmail.com
Sat Aug 6 21:37:56 UTC 2016


Hi Hannes,

If you have a spare moment, could you check this new warning?
This code was added recently in bc6dd798
"multipathd: Add 'sysfs' prioritizer"

Thank you.


clang -Wunused -Wstrict-prototypes -O2 -g -pipe -Wformat-security -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-size=4 -fPIC -DLIB_STRING=\"lib64\" -DRUN_DIR=\"run\"
-Werror -I../libmpathcmd -DLIBDM_API_FLUSH -D_GNU_SOURCE -DLIBDM_API_COOKIE -DLIBUDEV_API_RECVBUF -DUSE_SYSTEMD=229 -DLIBDM_API_DEFERRED -c -o discovery.o discovery.c
discovery.c:513:33: error: comparison of constant 18446744073709551615 with expression of type 'unsigned int' is always false [-Werror,-Wtautological-constant-out-of-range-compare]
        if (value == eptr || preferred == ULONG_MAX) {
                             ~~~~~~~~~ ^  ~~~~~~~~~




More information about the dm-devel mailing list